For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
OverviewCodaControlAPI ReferenceChangelog
OverviewCodaControlAPI ReferenceChangelog
  • Getting Started
    • Overview
    • Quickstart
  • MCP
    • MCP Integration
  • Capabilities
    • Simulation
    • Transpilation
    • QPU Submission
    • Agents
  • Node
    • Overview
    • Integration Guide
    • Protocol
    • QubiC Example
LogoLogo
On this page
  • Modes
  • Example
  • Conversation threads
  • Fast mode
  • Related endpoints
Capabilities

Agents

Use natural language to write quantum algorithms and learn quantum computing.
Was this page helpful?
Built with

The agents endpoint connects you to Coda’s AI agents, which can write quantum algorithms, generate and optimise circuits, explain concepts, and assist with quantum computing workflows. Responses are streamed back as server-sent events (SSE).

Modes

ModeDescription
buildAlgorithm building agent. Writes, debugs, and optimises quantum algorithms and circuits.
learnEducation agent. Explains quantum computing concepts and answers questions.

Example

1from conductorquantum import ConductorQuantum
2
3client = ConductorQuantum(token="<your-api-key>")
4for event in client.coda.agents.run(
5 messages=[{"role": "user", "content": "Create a 3-qubit GHZ state circuit in Qiskit"}],
6 mode="build",
7):
8 print(event)

The response is streamed. Each event contains a type field (content, tool_call, completed, or error) and associated data.

Conversation threads

Pass a thread_id to continue a previous conversation:

1{
2 "messages": [
3 {"role": "user", "content": "Now add a measurement to all qubits"}
4 ],
5 "thread_id": "<thread-id-from-previous-response>"
6}

The X-Thread-Id response header contains the thread ID for new conversations.

Fast mode

Set "fast": true for lower latency responses using a faster model. This trades some response quality for speed.

Related endpoints

  • POST /agents: chat with a Coda AI agent
  • GET /agents: list available agent modes

See the Coda API Reference for full request and response schemas.