Skip to content

Latest commit

 

History

History

README.md

Alliance / advanced examples

These examples target the full MCP surface via setupAllianceServer from @will-cppa/pinecone-read-only-mcp/alliance:

  • suggest_query_params and the suggest-flow gate
  • guided_query with experimental.decision_trace
  • Built-in URL generators for mailing and slack-Cpplang

They assume a Pinecone index you control with compatible data (not necessarily the C++ Alliance production index). To bootstrap a neutral index from scratch, start with examples/quickstart/README.md.

Required environment

Copy .env.example to .env and set your API key. For C++ Alliance infrastructure, use PINECONE_INDEX_NAME=rag-hybrid as documented there.

Variable Required Notes
PINECONE_API_KEY Yes For live runs
PINECONE_INDEX_NAME Yes Dense index name (Alliance: rag-hybrid)

Optional: PINECONE_RERANK_MODEL, PINECONE_SPARSE_INDEX_NAME, etc. See docs/CONFIGURATION.md. The published CLI uses resolveAllianceConfig and defaults to rag-hybrid / bge-reranker-v2-m3 when those env vars are omitted. Demo constants: preset.ts.

Files

File Description
suggest-flow-demo.ts Manual suggest_query_params → query flow
guided-query-demo.ts guided_query and experimental.decision_trace
library-embedding-demo.ts Programmatic setupAllianceServer wiring
custom-url-generator.ts Custom URL generator registration
demo-mock-pinecone-client.ts Mock client with mailing namespace (no network)

Run from the repo root after npm run build:

npx tsx examples/alliance/suggest-flow-demo.ts

Shared in-process MCP transport helper: ../mcp-linked-transport.ts.