textrawl
byJeff Green

extract_memories

Extract entities and facts from text using LLM analysis

Extract entities, facts, and relationships from text using Claude. Requires ENABLE_MEMORY_EXTRACTION=true and ANTHROPIC_API_KEY.

Parameters

ParameterTypeRequiredDefaultDescription
textstringREQUIRED-Text to extract from (10-100000 chars)
sourceenumOPTIONALmanualSource: conversation, note, document, manual
storeResultsbooleanOPTIONALtrueStore extracted memories in database

Example Request

{
  "text": "Jeff prefers TypeScript and uses Supabase for his projects. He works at Acme Corp.",
  "source": "conversation",
  "storeResults": false
}

Response

Returns extracted entities with their types, observations, and relationships.

{
  "entities": [
    { "name": "Jeff", "type": "person", "observations": ["prefers TypeScript", "uses Supabase", "works at Acme Corp"] }
  ],
  "relations": [
    { "from": "Jeff", "relation": "works_at", "to": "Acme Corp" }
  ],
  "stored": false
}

Set storeResults: true to persist extracted memories to the database.

Errors

ErrorCauseFix
Memory extraction not enabledENABLE_MEMORY_EXTRACTION is falseSet ENABLE_MEMORY_EXTRACTION=true
Missing API keyNo ANTHROPIC_API_KEY configuredSet ANTHROPIC_API_KEY in .env

On this page