For the complete documentation index, see llms.txt. This page is also available as Markdown.

Wizard API

Integrate AI chat in your product.

Chat API has been deprecated in favor of the 🧙🏻‍♂️ AIKEK Wizard, the new method of delivering AIKEK Universal Agents and Fractal data infra to builders.

Knowledge Ask Json

post

Answer a question using the Fractal knowledge engine.

This endpoint returns a JSON object with answer, sources, and sentiment fields. Sentiment is a domain-agnostic integer in the [1, 10] range, where 1 is very negative and 10 is very positive.

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body

Payload for the JSON-mode knowledge ask endpoint.

Attributes

question: str The user's question to answer. search_mode: Literal["deep", "fast", "ultrafast"] Retrieval depth preset. Controls number of documents fetched.

questionstringRequired

User question

search_modestring · enumOptional

Retrieval depth preset

Default: fastPossible values:
Responses
200

Successful Response

application/json

Response model for JSON-mode knowledge ask.

Attributes

answer: str Final answer text. Markdown is allowed. sources: list[str] Deduplicated list of source URLs used for the answer. sentiment: int Domain-agnostic sentiment on a 1–10 scale (1 very negative, 10 very positive).

answerstringRequired
sourcesstring[]Required
sentimentinteger · min: 1 · max: 10Required
post/knowledge/ask
POST /knowledge/ask HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 40

{
  "question": "text",
  "search_mode": "fast"
}
{
  "answer": "text",
  "sources": [
    "text"
  ],
  "sentiment": 1
}

Chat API Costs

Wizard API has a flat fee of 2 credits per request. Learn more about API Credits at API Pricing.

API Usage Examples

Last updated