speaker-context-layer

speaker-context-layer

Local MCP server for private, consent-based speaker identification and attribution, with per-language voiceprints and calibrated match thresholds. It lets AI assistants know who is speaking in a room or transcript without cloud services.

Category
访问服务器

README

Speaker Context Layer

AI knows who logged in. It has no idea who is in the room.

A local MCP server that tells any AI assistant who is speaking. Voiceprints never leave your machine — no account, no cloud.

[Sammy]: We push the follow-up to Thursday.
[Amara]: I'll own the documentation pack.
[Wei]: Can we revisit the budget line first?
[UNKNOWN SPEAKER]: I don't agree with that.

Try it in two minutes

pip install git+https://github.com/sammyghe/speaker-context-layer.git
scl-demo

It asks for a name, records 8 seconds, repeats for each person — then guesses who is speaking. Nothing is kept: scl-demo --reset deletes it.

Use it in an assistant

Claude Code

claude mcp add speaker-context-layer -- speaker-context-layer

Claude Desktop — add to claude_desktop_config.json:

{ "mcpServers": { "speaker-context-layer": { "command": "speaker-context-layer" } } }

Then say:

Use record_and_enroll to save my voice as Sammy in English — I consent, verbally, right now.

Setup for Gemini CLI and troubleshooting: docs/mcp-clients.md

Where it works, honestly

Claude Code, Claude Desktop, Gemini CLI Yes — local, today
Claude mobile / voice Not yet — needs a remote server
ChatGPT text Poorly — connectors are mostly limited to search/fetch
ChatGPT voice mode No — MCP tools are switched off during voice conversations

Voice mode is the least available place, which is the opposite of what you'd guess. An MCP tool call carries text — by the time the model calls a tool, the audio is already transcribed and gone, so no tool can reach the waveform it would need. Speaker identity has to be computed alongside a voice conversation by something holding the microphone, which is exactly what scl-room does.

Full explanation, and what a Connector Directory listing would cost: docs/where-it-runs.md


What it does that others don't

One person, several voiceprints — one per language. A voice embedding shifts when you switch language, so a code-switching speaker reads as two different people. Enroll each person once per language they use:

enroll_speaker(name="Sammy", language="en", ...)
enroll_speaker(name="Sammy", language="lg", ...)

It refuses to guess. Three answers, not two: a name, NEW_SPEAKER, or AMBIGUOUS when two people score too closely. Misattributing a decision is worse than admitting you don't know.

The threshold is yours, not inherited. Everyone else ships one number tuned on English-heavy data. On other accents that number is wrong — and it fails silently, returning a confident wrong name. So it ships unset, every answer is marked calibrated: false, and you fix it with your own voices:

scl-calibrate ./clips --population "Kampala team, EN/LG" --apply

It reports the gap between your worst genuine match and your best impostor — and refuses to invent a threshold when the two overlap.

The reasoning, the evidence, and what would prove it wrong: THESIS.md


Not authentication

Use it to label a transcript, follow a conversation, or caption a meeting. Never to unlock anything, approve a payment, gate access, or stand in for a signature. It cannot detect a recording or a cloned voice. A 0.96 score is not a signature.

Tools

Tool
record_and_enroll Record a consenting person, store the print, delete the clip
record_and_identify Record, identify, delete the clip
enroll_speaker Store a voiceprint from a file
identify_speaker Attribute a clip, or return NEW_SPEAKER / AMBIGUOUS
list_known_speakers Roster, languages, consent records
forget_speaker Erase one language or the whole person
list_microphones Available inputs
calibration_status Whether the threshold has been tested on your voices

Writing tools refuse without consent_confirmed=true and a consent_method describing how the person agreed.

Your data

~/.speaker-context-layer/registry.json

Voiceprints, consent records, your threshold. Treat it as biometric data — it is gitignored, and CI fails the build if audio or a registry is ever committed. See SECURITY.md.

Honest status

v0.1.0. The logic is tested (22 tests, ~0.5s). Accuracy on real voices is not established — no calibration run has happened yet. That is the next real step, and the software tells you so on every answer instead of hiding it.

Composes with

pyannote.audio (MIT) for diarization on long recordings — this project does not attempt it. Picovoice Eagle drives the experimental live room (scl-room).

Roadmap

  • [ ] Calibration on real Ugandan English, Luganda, and Swahili-English code-switching
  • [ ] Published calibration profiles per population, so others start from a real number
  • [ ] Evaluate Intron Sahara as an African-language embedding backend
  • [ ] Consent ceremony on first contact — chime, ask, wait, then enroll

Credits

Built by Sammy Gedamu with Claude Code as engineering coworker — architecture, research, and implementation paired throughout.

MIT — see LICENSE.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选