Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/netmindai-open/narranexus/attachments.pygit clone --depth 1 https://github.com/NetMindAI-Open/NarraNexusWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.01380 |
| Opus 5 | $0.00000 | $0.00690 |
| Sonnet 5 | $0.00000 | $0.00276 |
| Haiku 4.5 | $0.00000 | $0.00138 |
Grade A, and why
attachments.py scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 124 lines — stays where its author put it; the contents beside it link to each section on GitHub.
2026-07-22 — MIME sniffing moved to the shared utils helper
The local _sniff_mime_type + _audio_video_container_override pair
moved to [[mime_sniff]] so all three upload/ingest paths (this route, IM
channels, team-chat uploads) classify identically. One behavior delta: a
libmagic application/octet-stream verdict now falls through to the
extension guess instead of winning outright, so extension-typed text formats
(.md, .csv) get their real MIME. The container override semantics are
unchanged.
agents/attachments.py
Why it exists
HTTP boundary for the chat-attachment lifecycle: a multipart upload that
returns a server-issued file_id, plus a raw-bytes endpoint the
frontend uses to render image thumbnails inline. Kept separate from
agents/files.py because chat attachments have a different storage
shape (date-partitioned subdirs + sidecar index) and a different
access pattern (referenced by file_id, not browsed by name).
Whisper transcription runs for every audio/* upload regardless
of how the user produced it — the agent must always receive the
spoken content via the system-prompt attachment marker, whether the
clip came from in-browser dictation or from a file the user attached.
The route's source query parameter is purely a frontend-render
hint, normalised on the way out and echoed back so the persisted
attachment dict carries it through chat history reload:
source=recording— the in-browser AudioRecorder produced a voice memo. Frontend rendersVoiceTranscript(transcript text in place of the message bubble).- omitted /
source=upload/ anything else — Paperclip / drag-drop / paste. Frontend renders an ordinary file chip; the transcript still reaches the agent via the system prompt but is not surfaced in the UI (the user attached a file, they didn't dictate, so showing the transcript would be confusing).
Transcription routes through the same OpenAI-protocol provider system
that powers chat (UserProviderService → SystemProviderService →
settings.openai_api_key), so any user with a compatible provider
gets transcription "for free". Failures never break the upload — they
degrade to transcript=null and the response also exposes
transcription_available so the frontend can surface a "voice
unavailable" message specifically on the recording path.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 124 lines · 0 tokens per session scan A b80b611a08a4
attachments.py is an agent published in the GitHub repository NetMindAI-Open/NarraNexus (84 stars, last pushed 9d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,380 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other agents, from other repositories
pixel-art-animation-reviewer
Independent reviewer of pixel-art ANIMATION quality (loop seamlessness, motion physics, multi-component motion, frame timing, period selection, particle determinism). One of four specialized review roles in the pixel-art-quality-board orchestrator. Use when the user asks to "check animation timing", "verify loop…
45-corporate-development
You are the Head of Corporate Development. You own inorganic growth — the things the company buys, invests in, or sells rather than builds: acquisitions, minority investments, joint ventures, and divestitures. Where BD & Partnerships (Agent 33) owns contractual growth (deals where two companies stay separate and…
codex-second-opinion
Get an independent opinion from OpenAI Codex (GPT-5) on a design decision, an approach, a tradeoff, or an unfamiliar area of the codebase — a general-purpose Codex liaison for questions that don't fit the reviewer, debugger, or implementer agents. Use when the user asks to "ask Codex", wants Claude's work…
alchemist
Creative technologist who sees the browser as an unexplored physics engine. Consult when building UI that needs to feel alive - scroll-driven reveals, morphing transitions, spatial animation systems, anything where the interaction itself IS the product. Thinks in weight, tension, and breath before thinking in code.…
designer
Ornamental design specialist for historical and modern style analysis, colorblind-accessible palettes, and AI-assisted image generation using Z-Image.
AGENTS.motiscope
Agent "AGENTS.motiscope" from KumarSashank/motiscope, covering motiscope — recreate animations from screen recordings, the division of labor, commands and workflows.