Root causes of zero entity extraction:
1. IngestWorker used WikiLinkFallbackExtractor (wiki links only)
Fix: Use LlmEntityExtractor when LLM_ENDPOINT is set
2. ExtractedEntity.entity_type vs LLM returning "type"
Fix: serde alias "type" -> entity_type, default confidence
3. Reasoning models output <think>...</think> before JSON
Fix: strip_thinking_tags() extracts JSON from response
4. Reflection verification crashes pipeline on parse failure
Fix: graceful fallback, keep all entities if reflection fails
Tested with reasoning-predictor (qwen2.5:3b) via port-forward.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Changes
Entity Extraction
clean_llm_response(): strips<think>tags, markdown fences, extracts JSON[...]not{entities: [...]})Fact Extraction (NEW)
K8s Deployment
command: ["/app/mem"](fix args replacing CMD)E2E Tested (local Ollama qwen2.5:3b)
Zep Paper Alignment (§2.2)
Entity extraction fixes: - clean_llm_response() strips <think> tags, markdown fences, extracts JSON - Handle array responses (wrap in {"entities": [...]}) - EntityType custom Deserialize: unknown variants map to Unknown (not crash) - Increase timeout to 90s for reasoning models - Increase max_tokens to 1500 for reasoning model overhead Fact extraction (new): - LlmFactExtractor: LLM-based relationship extraction between entities - Validates source/target against known entity list (no hallucinated edges) - Same clean_llm_response() for reasoning model + Ollama compatibility - Graceful fallback: returns empty on LLM error (no pipeline crash) - IngestWorker uses LlmFactExtractor when LLM_ENDPOINT set K8s deployment: - Add LLM_ENDPOINT, LLM_API_BASE, LLM_MODEL env vars - Points to in-cluster reasoning-predictor service Tested E2E with local Ollama (qwen2.5:3b): - 12 entities extracted (person, tool, concept, organization) - 5 edges with meaningful relationships and facts - 781 tests passView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.