Add Brand Knowledge
add_knowledgeAdd a source to the brand's knowledge base.
Knowledge is the brand-truth Trakkr feeds into AI-facing content generation. Feed in a positioning doc, a product page, a founder Q&A, so generated articles and answers stay accurate. Two modes:
source_type='text': paste raw text. Needs
content(roughly 50 to 100,000 tokens; under ~200 characters is rejected as too short).source_type='url': ingest a web page. Needs
url(http/https). The page is fetched and its text extracted server-side.
Processing is async. The call returns fast with status='pending'; the source is then chunked and embedded in the background. Poll get_knowledge(brand_id, view='sources') until status is 'ready' (or 'error'). Duplicate content (same text already added) is rejected.
Args: brand_id: The brand to add knowledge to (required). source_type: 'text' or 'url' (required). content: The raw text. Required when source_type='text'. url: The page URL. Required when source_type='url'. name: Optional display name. Defaults to a derived label or the page title.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | ||
| name | No | ||
| content | No | ||
| brand_id | Yes | ||
| source_type | Yes | ||
| user_intent | No | Analytics hint: the user's latest request in one short sentence. Omit secrets and prior chat. |