AI-generate thesis from current regime
curl --request POST \
--url https://api.example.com/api/graph/v1/thesis/generate \
--header 'Content-Type: application/json' \
--data '
{
"timeframe": "swing",
"catalyst_ids": [
"<string>"
],
"risk_ids": [
"<string>"
],
"sectors": [
"<string>"
]
}
'import requests
url = "https://api.example.com/api/graph/v1/thesis/generate"
payload = {
"timeframe": "swing",
"catalyst_ids": ["<string>"],
"risk_ids": ["<string>"],
"sectors": ["<string>"]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
timeframe: 'swing',
catalyst_ids: ['<string>'],
risk_ids: ['<string>'],
sectors: ['<string>']
})
};
fetch('https://api.example.com/api/graph/v1/thesis/generate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/graph/v1/thesis/generate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'timeframe' => 'swing',
'catalyst_ids' => [
'<string>'
],
'risk_ids' => [
'<string>'
],
'sectors' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/graph/v1/thesis/generate"
payload := strings.NewReader("{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/graph/v1/thesis/generate")
.header("Content-Type", "application/json")
.body("{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/graph/v1/thesis/generate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"thesis_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"status": "active",
"direction": "bullish",
"timeframe": "intraday",
"narrative": "<string>",
"sectors": [
"<string>"
],
"confidence": 0.5,
"source": "ai_generated",
"valid_until": "2023-11-07T05:31:56Z",
"regime_dominant": "<string>",
"regime_confidence": 123,
"regime_vector": {},
"vix_regime": "<string>",
"day_type": "<string>",
"catalysts": [
"<string>"
],
"invalidation_conditions": [
"<string>"
],
"catalyst_ids": [
"<string>"
],
"risk_ids": [
"<string>"
],
"debate_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"macro_event_id": "<string>",
"symbols": [
"<string>"
],
"regime_drifted": false
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Thesis
AI-generate thesis from current regime
Generate a thesis using AI based on current market regime context and sector trends.
Expected latency: <5s (single LLM call with structured output).
The regime context + sector trends are pre-fetched and passed as prompt context.
POST
/
api
/
graph
/
v1
/
thesis
/
generate
AI-generate thesis from current regime
curl --request POST \
--url https://api.example.com/api/graph/v1/thesis/generate \
--header 'Content-Type: application/json' \
--data '
{
"timeframe": "swing",
"catalyst_ids": [
"<string>"
],
"risk_ids": [
"<string>"
],
"sectors": [
"<string>"
]
}
'import requests
url = "https://api.example.com/api/graph/v1/thesis/generate"
payload = {
"timeframe": "swing",
"catalyst_ids": ["<string>"],
"risk_ids": ["<string>"],
"sectors": ["<string>"]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
timeframe: 'swing',
catalyst_ids: ['<string>'],
risk_ids: ['<string>'],
sectors: ['<string>']
})
};
fetch('https://api.example.com/api/graph/v1/thesis/generate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/graph/v1/thesis/generate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'timeframe' => 'swing',
'catalyst_ids' => [
'<string>'
],
'risk_ids' => [
'<string>'
],
'sectors' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/graph/v1/thesis/generate"
payload := strings.NewReader("{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/graph/v1/thesis/generate")
.header("Content-Type", "application/json")
.body("{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/graph/v1/thesis/generate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"timeframe\": \"swing\",\n \"catalyst_ids\": [\n \"<string>\"\n ],\n \"risk_ids\": [\n \"<string>\"\n ],\n \"sectors\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"thesis_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"status": "active",
"direction": "bullish",
"timeframe": "intraday",
"narrative": "<string>",
"sectors": [
"<string>"
],
"confidence": 0.5,
"source": "ai_generated",
"valid_until": "2023-11-07T05:31:56Z",
"regime_dominant": "<string>",
"regime_confidence": 123,
"regime_vector": {},
"vix_regime": "<string>",
"day_type": "<string>",
"catalysts": [
"<string>"
],
"invalidation_conditions": [
"<string>"
],
"catalyst_ids": [
"<string>"
],
"risk_ids": [
"<string>"
],
"debate_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"macro_event_id": "<string>",
"symbols": [
"<string>"
],
"regime_drifted": false
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Body
application/json
Request body for AI thesis generation.
Optional direction hint
Available options:
bullish, bearish, neutral Target timeframe
Available options:
intraday, swing, position Pre-selected catalyst IDs from taxonomy
Pre-selected risk IDs from taxonomy
Pre-selected sectors
Response
Successful Response
Full thesis model for API responses.
Thesis lifecycle status.
Available options:
active, invalidated, expired, realized Available options:
bullish, bearish, neutral Available options:
intraday, swing, position 1-2 sentence human-readable thesis
Ranked by thesis fit
Thesis-specific conviction 0-1
Required range:
0 <= x <= 1Available options:
ai_generated, user_defined, debate_derived, news_derived Auto-set based on timeframe
V5 dominant state at creation
V5 Shannon entropy confidence (0-100)
Full 6-state probabilities (for audit)
Show child attributes
Show child attributes
VIX regime label at creation
Day classification at creation
Structured catalyst IDs
Structured risk IDs
Driving MacroEvent (graph event_id)
True if current regime differs from thesis regime