Skip to content

v0.3.0

Choose a tag to compare

@nevindra nevindra released this 19 Feb 06:37
· 237 commits to master since this release

v0.3.0

This release adds PostgreSQL/pgvector as a first-class storage backend, a composable retrieval pipeline with hybrid search and re-ranking, new ingest extractors (CSV, JSON, DOCX), suspend/resume for agents and workflows, and a large set of agent memory improvements.

Highlights

PostgreSQL + pgvector Storage

New store/postgres package — full Store, KeywordSearcher, and MemoryStore backed by PostgreSQL with pgvector. Share one *pgxpool.Pool across your entire app.

pool, _ := pgxpool.New(ctx, connString)

store := postgres.New(pool)
memStore := postgres.NewMemoryStore(pool)
  • HNSW indexes for cosine distance vector search
  • tsvector/tsquery with GIN index for full-text keyword search
  • Semantic deduplication in SQL (no brute-force scanning)
  • Pure Go — only dependency: github.com/jackc/pgx/v5

Retrieval Pipeline

Composable hybrid search with re-ranking for RAG:

  • Retriever and Reranker interfaces
  • HybridRetriever — vector + keyword search with Reciprocal Rank Fusion
  • ScoreReranker (zero-dependency) and LLMReranker (LLM-powered)
  • KeywordSearcher — optional Store capability via type assertion

Suspend/Resume

Pause agent or workflow execution to await external input, then continue from where it left off:

  • Suspend(payload) from any step function or processor
  • ErrSuspended with Resume(ctx, data) to continue
  • Works in Workflows, LLMAgent, and Network

Ingest Extractors & Chunk Metadata

  • csv.Extractor, json.Extractor, docx.Extractor (all pure Go)
  • ChunkMeta type — page numbers, section headings, images per chunk
  • MetadataExtractor interface — opt-in structured metadata from extractors

All Changes

Added

  • PostgreSQL + pgvector storage (store/postgres)
  • Retrieval pipeline — Retriever, Reranker, KeywordSearcher, HybridRetriever, ScoreReranker, LLMReranker
  • Suspend/Resume — Suspend(), ErrSuspended, Resume(), ResumeData(), StepSuspended
  • Ingest extractors — CSV, JSON, DOCX with MetadataExtractor interface
  • ChunkMeta and Image types for per-chunk metadata
  • MaxHistory(n) — control message history depth per thread
  • ScoredMessage, ScoredChunk, ScoredSkill, ScoredFact scored result types
  • WithRetry(provider) — automatic retry with exponential backoff on 429/503
  • CrossThreadSearch and MinScore for semantic recall tuning
  • Auto fact extraction, trivial message filter, semantic supersedes, probabilistic decay
  • Attachment type for multimodal content (images, PDFs)
  • Scheduler primitive for polling due actions
  • Parallel tool execution in LLMAgent and Network
  • StreamingAgent interface
  • AgentTask.Context typed accessors
  • Built-in conversation memory, user memory, and cross-thread recall wiring

Changed

  • KnowledgeTool delegates to Retriever interface (backward-compatible)
  • PDF extractor upgraded to MetadataExtractor
  • Breaking: ChatMessage.Images → ChatMessage.Attachments
  • Breaking: Search methods return Scored* types with Score float32
  • Breaking: CrossThreadSearch and WithUserMemory now take EmbeddingProvider as required argument
  • Breaking: AgentTask.Context type changed from map[string]string to map[string]any
  • Breaking: Workflow.Execute returns *WorkflowError on step failure
  • Extracted shared runLoop from LLMAgent and Network (no public API change)

Fixed

  • Parent-child chunk resolution works end-to-end
  • SQLITE_BUSY eliminated with single shared connection
  • Data race in ObservedProvider.ChatStream
  • Cross-thread recall now filters by score and excludes current thread
  • Workflow retry works on all step types; ForEach cancels on first failure
  • Network routing no longer paraphrases user messages
  • Background persist completes even on context cancellation
  • AgentStep propagates context and attachments to sub-agents

Full Changelog: v0.2.1...v0.3.0