Skip to content

feat: add MiniMax as a supported embedding and LLM provider#181

Open
octo-patch wants to merge 76 commits intoCortexReach:mainfrom
octo-patch:feat/add-minimax-provider-support
Open

feat: add MiniMax as a supported embedding and LLM provider#181
octo-patch wants to merge 76 commits intoCortexReach:mainfrom
octo-patch:feat/add-minimax-provider-support

Conversation

@octo-patch
Copy link

Summary

Add MiniMax as an officially documented embedding and LLM provider for memory-lancedb-pro.

Changes

  • src/embedder.ts: Add MiniMax embo-01 model (1536 dimensions) to EMBEDDING_DIMENSIONS map; add MiniMax API URL and model name detection in getProviderLabel() for better error messages
  • README.md: Add MiniMax to the embedding providers table; add MiniMax config examples for both embedding and LLM (smart extraction) usage
  • README_CN.md: Same documentation updates in Chinese

Why MiniMax?

MiniMax provides OpenAI-compatible APIs at https://api.minimax.io/v1 for both embeddings and chat completions. Key highlights:

  • MiniMax-M2.5 LLM with 204K context window — ideal for smart extraction on long conversations
  • embo-01 embedding model with 1536 dimensions
  • Drop-in compatible — no code changes needed beyond configuration

Test Plan

  • All existing tests pass (npm test — 100% green)
  • embo-01 correctly resolves to 1536 dimensions via getVectorDimensions()
  • getProviderLabel() detects MiniMax from both URL and model name patterns
  • README examples use correct API endpoint and model names

Admin and others added 30 commits March 3, 2026 10:30
feat: Implement lifecycle-aware memory decay and enhance retriever robustness, CLI, and documentation.
…ing` configuration, clarify default behaviors, and remove `AccessTracker` flush.
feat: Add plugin manifest regression test, implement `embedding.chunk…
…pture logging, and improve smart extraction fallback.
feat: Reduce smart extraction message threshold to 2, enhance auto-capture logging, and improve smart extraction fallback.
…model to gpt-4o-mini in example configurations.
… with built-in memory, and simplify the quick start guide.
…, and feature development, and enhance LLM client with improved logging and error handling.
feat: Add new memory plugins for host validation, release consistency…
…o-capture debug logging, and update .gitignore with new plugin ignore rules.
… text processing skip logic with debug logging, and refine memory extraction prompts to improve memory classification.
…extractor for advanced noise filtering and learning, with accompanying documentation.
win4r and others added 30 commits March 10, 2026 05:49
* "Claude PR Assistant workflow"

* "Claude Code Review workflow"
…urce typing

- store.ts: add .distanceType('cosine') to vectorSearch (critical: L2 default drops valid results)
- store.ts: add getFtsStatus(), rebuildFtsIndex() for BM25 health diagnostics
- retriever.ts: extend source typing with 'cli' for CLI trace distinction
- cli.ts: mark CLI retrievals with source='cli', add reindex-fts command
- test: add vector-search-cosine.test.mjs (4 tests)
…ce tracking

Extends OpenViking's smart memory architecture with context-aware support:

- smart-metadata.ts: add SupportInfoV2/ContextualSupport types, normalizeContext,
  parseSupportInfo (V1→V2 migration), updateSupportStats; fix LegacyStoreCategory
  missing 'reflection'
- memory-categories.ts: extend DedupDecision with support/contextualize/contradict,
  add contextLabel to DedupResult, supported count to ExtractionStats
- extraction-prompts.ts: extend dedup prompt with 3 new decisions + context_label
- smart-extractor.ts: add handleSupport/handleContextualize/handleContradict handlers
  in processCandidate pipeline, extract contextLabel in llmDedupDecision
- test: add smart-metadata-v2.mjs (6 tests, all passing)
- smart-extractor.ts: handleMerge now accepts contextLabel and updates
  support stats after successful merge (aligns with support/contextualize/
  contradict handlers)
- smart-metadata.ts: stringifySmartMetadata caps arrays to prevent JSON
  bloat (sources≤20, history≤50, relations≤16)
- test/context-support-e2e.mjs: 3 E2E scenarios testing support,
  contextualize, and contradict decisions end-to-end
Blocking:
1. Add smart-metadata-v2, vector-search-cosine, context-support-e2e
   to npm test chain (package.json)
2. Rewrite smart-metadata-v2.mjs to import production code via jiti
   (normalizeContext, parseSupportInfo, updateSupportStats, etc.)
3. Rewrite vector-search-cosine.test.mjs to use real MemoryStore
   against temp LanceDB (no more fakeStore)

Suggestions:
4. Fix '下午' mapping: evening → afternoon (add to vocabulary)
5. parseSupportInfo: validate slice numeric fields (confirmations,
   contradictions, strength, last_observed_at)
6. Document slice truncation drift as accepted trade-off
7. dropIndex: log warning instead of silently swallowing errors
…ive noise filtering with non-discriminative embeddings

When the embedding model produces identical vectors for all inputs (e.g.
deterministic mock embeddings in tests), every text matches every noise
prototype with cosine similarity 1.0, causing the noise filter to reject
all content. Smart extraction is skipped entirely, falling back to regex
which also captures nothing.

Add a self-diagnostic after init(): if the first two prototype vectors
have cosine similarity > 0.98, the bank recognizes the embedding model
is degenerate and disables itself.

This fixes the flaky smart-extractor-branches.mjs test on master
(all 9 scenarios now pass reliably).
…it/clean-recall-text-final

Validated locally.

- Host functional test passed
- Agent E2E passed
- Web dashboard / WebChat check passed
- Visible recall text and auto-recall injected text are now cleaned up as expected
- No blocking regression found from this PR

I did observe one non-blocking model response inconsistency in a JSON prompt during manual chat testing, but the underlying recall output was correct and it does not appear to be caused by this PR.
…al-and-context

# Conflicts:
#	package.json
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…coring

Remove redundant vectorScore + 15% bonus branch from fuseResults Math.max.
Weighted fusion (vectorScore * vectorWeight + bm25Score * bm25Weight) is now
the primary scoring formula. BM25 high-score floor (>= 0.75) preserved for
exact keyword matches.

Closes CortexReach#130 (Layer 3)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
updateSupportStats returns a new SupportInfoV2 object — the original is
not mutated. The old code discarded the return value and persisted the
empty original, causing merge+contextLabel to always write empty
support_info ({global_strength:0.5, total_observations:0, slices:[]}).
* chore: add version consistency check and auto-sync

Add CI job to verify package.json and openclaw.plugin.json versions match.
Add npm version hook to auto-sync openclaw.plugin.json on version bump.

* fix: stabilize plugin version sync

---------

Co-authored-by: Heng Xia <pope@Hengs-Mac-mini.local>
…al-and-context

# Conflicts:
#	package.json
…al-and-context

feat: 检索正确性修复 + 情境化 SupportInfo — 适配 master 架构
Add support info regression coverage
…generate-embedding-guard

fix: NoisePrototypeBank degeneracy guard — fix flaky smart-extractor-branches test
…-130

fix(retriever): make vectorWeight/bm25Weight actually affect fusion scoring
…sion-weighting-130

Revert "fix(retriever): make vectorWeight/bm25Weight actually affect fusion scoring"
…coring

Remove redundant vectorScore + 15% bonus branch from fuseResults Math.max.
Weighted fusion (vectorScore * vectorWeight + bm25Score * bm25Weight) is now
the primary scoring formula. BM25 high-score floor (>= 0.75) preserved for
exact keyword matches.

Closes CortexReach#130 (Layer 3)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…-130-v2

fix(retriever): make vectorWeight/bm25Weight actually affect fusion scoring
- Add MiniMax embo-01 (1536 dims) to EMBEDDING_DIMENSIONS map
- Add MiniMax API detection in getProviderLabel() for better error messages
- Add MiniMax embedding + LLM config examples in both README.md and README_CN.md
- Document MiniMax-M2.5 (204K context) as an LLM option for smart extraction

MiniMax provides OpenAI-compatible APIs at https://api.minimax.io/v1 for both
embeddings and chat completions, making it a drop-in provider choice.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants