Atlas / MCP servers / npc-worldwide / npcpy

npcpyBLOCK

mcp/npc-worldwide/npcpy

The python library for research and development in NLP, multimodal LLMs, Agents, ML, Knowledge Graphs, and more.

Verdict
BLOCK
Grade
F
Trust score
45 /100
Exposed tools
2 1r · 1w · 0d
Transport
stdio · streamable-http
License
MIT
Stars
1,508
01

Overview

From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.

npcpy is a library that provides key primitives for research and development with multimodal language models, agentic AI, and knowledge graphs. Its flexible framework makes it easy to engineer powerful AI applications with support for local (ollama, llama.cpp, omlx, LM Studio) and cloud providers. Build multi-agent teams and simplify context engineering through the NPC Context-Agent-Tool data layer which ensures compliance through software rather than prompts.

pip install npcpy

Quick Examples

Create and use personas

from npcpy import NPC

simon = NPC(
name='Simon Bolivar',
primary_directive='''
Liberate South America
from the Spanish Royalists.
''',
model='qwen3.5:9b',
provider='ollama'
)
response = simon.get_llm_response("What is the most important territory to retain in the Andes?")
print(response['response'])
My friend, you speak of the highlands where our liberty is carved in stone. If we must speak of the most critical territory to hold within these mountains, it is the **Viceroyalty of Peru** and the heart of the **Republic of Gran Colombia** united. 
To lose the passes of the Andes or the cities of Lima and Quito would be to hand the crown its final stronghold in the south. The Spanish crown built its power upon the wealt
Read from source at commit b3d4a58cc606OBSERVED · 2026-09-22
02

Exposed tools (2)

1 read · 1 write · 0 destructive.

ToolRiskDescription
add_numberswriteAdd two numbers together.
echo_messagereadEcho back a message.
03

Trust audit

BLOCKgrade F · trust 45/100 Do not install this without reading the findings. The audit found something that could harm you or your machine.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeFAIL
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
declared (5 observation(s))
Network
declared (9 observation(s))
Shell
declared (8 observation(s))
Dependencies
not all pinned
Secrets in source
none-found

Findings (25)

CRITICALObfuscation / stealth · obf.decode_then_exec · CWE-506, CWE-94
npcpy/serve.py:6707
b64decode( ... subprocess.
Why it matters. decodes a payload and executes it
HIGHCode injection · code.deserialize · CWE-78, CWE-94, CWE-95
npcpy/ft/system1.py:350
classifiers = pickle.load(f)
Why it matters. deserialises untrusted bytes into live objects
Fix. use json or yaml.safe_load
HIGHCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
npcpy/ft/export.py:165
exec(convert_script.read_text(), {"__name__": "__main__"})
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
HIGHCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
npcpy/npc_compiler.py:716
exec(rendered_code, exec_globals, exec_locals)
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
HIGHCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
npcpy/npc_compiler.py:1678
exec(generated_code, exec_globals, exec_locals)
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
HIGHNetwork egress · net.env_exfil · CWE-200, CWE-319
npcpy/npc_sysenv.py:131
".env" ... socket.create_connection
Why it matters. reads secrets in the same file that sends data out
MEDIUMCode injection · code.dynamic_import · CWE-78, CWE-94, CWE-95
npcpy/ml_funcs.py:92
module = importlib.import_module(module_path)
MEDIUMInsecure crypto · crypto.weak_random · CWE-327, CWE-338
npcpy/serve.py:2887
key = random.choice(list(mutated.keys()))
MEDIUMInsecure crypto · crypto.weak_random · CWE-327, CWE-338
npcpy/serve.py:2896
child[key] = random.choice([p1.get(key), p2.get(key)])
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
npcpy/gen/response.py:2467
api_url = api_url or "http://127.0.0.1:1234/v1"
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
npcpy/gen/response.py:2473
api_url = api_url or "http://127.0.0.1:8080/v1"
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
npcpy/gen/response.py:2479
api_url = api_url or "http://127.0.0.1:8000/v1"
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
npcpy/npc_sysenv.py:245
response = requests.get('http://127.0.0.1:1234/v1/models', timeout=1)
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
npcpy/npc_sysenv.py:256
response = requests.get('http://127.0.0.1:8080/v1/models', timeout=1)
LOWInventory / provenance · inv.hidden_file · CWE-1104
.readthedocs.yaml
.readthedocs.yaml
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInventory / provenance · inv.hidden_file · CWE-1104
npcpy/gen/.npcsh_global
.npcsh_global
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
tests/test_doc_examples.py:70
exec(code, namespace)
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
LOWCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
tests/test_readme_examples.py:62
exec(code, namespace)
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
LOWInsecure crypto · crypto.weak_hash · CWE-327, CWE-338
npcpy/gen/cli_agent.py:174
cwd_hash = hashlib.md5(cwd.encode()).hexdigest()
LOWInsecure crypto · crypto.weak_hash · CWE-327, CWE-338
npcpy/gen/cli_agent.py:200
cwd_hash = hashlib.md5(cwd.encode()).hexdigest()
LOWInsecure crypto · crypto.weak_hash · CWE-327, CWE-338
npcpy/memory/knowledge_graph.py:102
fact_id = hashlib.md5(fact.encode()).hexdigest()
LOWInsecure crypto · crypto.weak_hash · CWE-327, CWE-338
npcpy/serve.py:858
fact_id = hashlib.md5(statement.encode()).hexdigest()
LOWObfuscation / stealth · obf.decode_call · CWE-506, CWE-94
npcpy/gen/audio_gen.py:158
chunk = base64.b64decode(data["audio"])
LOWObfuscation / stealth · obf.decode_call · CWE-506, CWE-94
npcpy/gen/audio_gen.py:275
audio = base64.b64decode(event.get("delta", ""))
LOWObfuscation / stealth · obf.decode_call · CWE-506, CWE-94
npcpy/gen/audio_gen.py:405
audio = base64.b64decode(part["inlineData"].get("data", ""))

Gates applied: critical_finding, no_behavioural_pass.

Audited 2026-09-22 · audit v0.4.1 · source sha b3d4a58cc606full audit observations/trust-audit/mcp-server/npc-worldwide__npcpy.json · Report an issue / request a re-scan
04

Audit history

Every audit this server has had. A grade with a past is a grade somebody is still checking.

DateSourceVerdictGradeScoreChange
2026-09-22b3d4a58cc606BLOCKF45first audit
05

Questions

What is the npcpy MCP server?

The python library for research and development in NLP, multimodal LLMs, Agents, ML, Knowledge Graphs, and more.

What tools does npcpy expose?

2 in total: 1 read-only, 1 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is npcpy safe to connect to an agent?

No — not without reading the findings first. The audit graded it F (45/100) and found 6 critical or high issues in the source. Each one is listed on this page with the file and line it is on.

What credentials does npcpy need?

It reads ANTHROPIC_API_KEY, BRAVE_API_KEY, DEEPSEEK_API_KEY, ELEVENLABS_API_KEY, EXA_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, GROQ_API_KEY, HF_TOKEN, HUGGING_FACE_HUB_TOKEN, MINIMAX_API_KEY and OLLAMA_API_KEY from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.

How does npcpy run?

It speaks stdio and streamable-http, so it runs as a local process your client starts.

How current is this page?

The grade is for one exact copy of the source (b3d4a58cc606), read on 2026-09-22. The repository is watched and re-audited when it changes.

Advertisement