Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/design/cloud-agents/e2e-testing-strategy.md
Original file line number Diff line number Diff line change
Expand Up @@ -159,10 +159,8 @@ name in two different files). Current layout:
| File | Layer | Covers |
|---|---|---|
| `test_workflows_http_e2e.py` | real HTTP (`TestClient`) | `/v1/workflows/*`, spawn none+local+ephemeral, incl. one-step workflows |
| `test_query_direct_handler_e2e.py` | handler-direct | `/v1/query/direct` error paths |
| `test_step_executor_e2e.py` | step-executor dispatch (`get_step_executor(...).run(...)`) | single-step execution, spawn none+local+ephemeral |
| `test_workflow_definitions_e2e.py` | step-executor dispatch | full workflow-YAML execution, one step-executor call per step |
| `test_otel_tracing_e2e.py` | mid-layer (`execute_query_via_direct_executor`) | trace/span assertions for the query/direct path |
| `test_workflow_tracing_e2e.py` | `LocalWorkflowRunner` directly | trace/span assertions for the workflow-engine path |
| `mock_llm_server.py`, `mock_llm_env.py`, `test_mock_llm_*.py`, `jaeger_helpers.py`, `conftest.py` | infra | shared fixtures/mocks, not endpoint tests themselves |

Expand Down
12 changes: 5 additions & 7 deletions docs/design/cloud-agents/integration-architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,12 @@ graph TB
a2a["/a2a"]
end
subgraph new["New Endpoints"]
qd["/query/direct"]
qds["/query/direct/stream"]
wf["/workflows/*"]
at["/agent-tools"]
end

existing -->|build_agent| llamastack["Llama Stack"]
new --> bridge["query_executor.py\nvalidate + build StepInput"]
new --> bridge["workflow/\nstorage + executor_factory"]
end

bridge --> dispatch["get_step_executor()"]
Expand Down Expand Up @@ -222,7 +220,6 @@ graph TB
end

subgraph bridge["Bridge Layer (lightspeed-stack src/workflow/)"]
qe["query_executor.py"]
storage["storage.py"]
ef["executor_factory.py"]
end
Expand Down Expand Up @@ -264,8 +261,6 @@ graph TB

| Endpoint | Method | Purpose |
|---|---|---|
| `/v1/query/direct` | POST | Blocking query via DirectExecutor |
| `/v1/query/direct/stream` | POST | SSE streaming query |
| `/v1/workflows/run` | POST | Start a workflow (multi-step, or one-step for one-shot agent runs) |
| `/v1/workflows/{id}` | GET | Get workflow status |
| `/v1/workflows/{id}/approve` | POST | Approve a paused step |
Expand Down Expand Up @@ -375,6 +370,10 @@ graph LR
style future fill:#e8f5e9,stroke:#4caf50
```

> **Deferred:** the `/v1/query/direct` endpoints were removed to keep the
> workflow work focused; bring-back is tracked in jameswnl/lightspeed-stack#59.
> The status below describes the design target, not shipped endpoints.

### What's Done

| Component | Status |
Expand Down Expand Up @@ -475,7 +474,6 @@ Blue = cloud-agents. Orange = lightspeed-stack. Red = final migration steps.

| Component | Multi-pod safe? | Notes |
|---|---|---|
| `/query/direct` | Yes | Stateless per call |
| Conversation state | Yes (PostgreSQL) | Shared database |
| Workflow state | Yes (PostgreSQL) | Shared database |
| Running workflow tasks | No (in-memory) | Use Temporal for crash recovery |
Expand Down
178 changes: 0 additions & 178 deletions docs/devel_doc/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -6239,90 +6239,6 @@
}
}
},
"/v1/query/direct": {
"post": {
"tags": [
"query"
],
"summary": "Query Direct Handler",
"description": "Execute a query via DirectExecutor (no Llama Stack).\n\nParameters:\n request: FastAPI request (consumed by @authorize decorator).\n body: Query parameters (field names match /query).\n auth: Authentication tuple (consumed by @authorize decorator).\n\nReturns:\n Response matching QueryResponse field names.",
"operationId": "query_direct_handler_v1_query_direct_post",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/QueryDirectRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"additionalProperties": true,
"type": "object",
"title": "Response Query Direct Handler V1 Query Direct Post"
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
},
"/v1/query/direct/stream": {
"post": {
"tags": [
"query"
],
"summary": "Query Direct Stream Handler",
"description": "Stream a query via DirectExecutor as SSE events.\n\nToken-by-token streaming is active when tools or MCP servers\nare configured. Without tools, yields a single complete event.\n\nParameters:\n request: FastAPI request (consumed by @authorize decorator).\n body: Query parameters (field names match /query).\n auth: Authentication tuple (consumed by @authorize decorator).\n\nReturns:\n StreamingResponse with SSE events.",
"operationId": "query_direct_stream_handler_v1_query_direct_stream_post",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/QueryDirectRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
},
"/v1/streaming_query": {
"post": {
"tags": [
Expand Down Expand Up @@ -18889,100 +18805,6 @@
}
]
},
"QueryDirectRequest": {
"properties": {
"query": {
"type": "string",
"title": "Query",
"description": "The query string",
"examples": [
"What is Kubernetes?"
]
},
"conversation_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Conversation Id",
"description": "Conversation ID for multi-turn (requires PostgreSQL transcript store)"
},
"provider": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Provider",
"description": "The optional provider"
},
"model": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Model",
"description": "The optional model"
},
"system_prompt": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "System Prompt",
"description": "The optional system prompt"
},
"mcp_servers": {
"anyOf": [
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Mcp Servers",
"description": "MCP server names from config (None = all configured)"
},
"output_schema": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"title": "Output Schema",
"description": "JSON Schema for structured output"
}
},
"type": "object",
"required": [
"query"
],
"title": "QueryDirectRequest",
"description": "Request body for POST /v1/query/direct.\n\nField names match QueryRequest for API compatibility.\n\nAttributes:\n query: The query string.\n conversation_id: Optional conversation ID for multi-turn.\n provider: Optional provider name.\n model: Optional model name.\n system_prompt: Optional system prompt.\n mcp_servers: Optional MCP server names from config.\n output_schema: Optional JSON Schema for structured output."
},
"QueryRequest": {
"properties": {
"query": {
Expand Down
Loading
Loading