Markdown Converter
Agent skill for markdown-converter
**Status:** ACTIVE
Loading actions...
Status: ACTIVE
Current Model: F16 (evony-7b-3800-f16) - 15.24 GB loaded
RAG Status: 16,962 chunks | 101,853 KG entities | 346,398 relationships
| Area | Files Modified | Status |
|---|---|---|
| LM Studio Integration | 3 Python files, 2 docs | β Complete |
| LM Studio Presets | 7 presets + README | β Complete |
| Knowledge Graph Enhancement | 15+ scripts | β Complete |
| Index Rebuild/Recovery | 10+ scripts | β Complete |
| RAG Features | 10+ new files | β Complete |
| Documentation Updates | 6 docs updated | β Complete |
| File | Path | Lines | Purpose |
|---|---|---|---|
lmstudio_control.py | evony_rte/ | 591 | Python control script for model switching |
lmstudio_manager.py | evony_rte/ | 1000+ | Full LM Studio manager |
mcp_lmstudio_tools.py | evony_rte/ | 400+ | MCP tools for LM Studio |
# Check what's loaded
lms ps
# Switch models
python evony_rte/lmstudio_control.py status
python evony_rte/lmstudio_control.py switch evony-7b-3800-rtx3090ti
python evony_rte/lmstudio_control.py presets
lmstudio_presets/| Preset | Temp | Use Case |
|---|---|---|
evony-master-expert.preset.json | 0.4 | RECOMMENDED All-in-one |
evony-exploit-hunter.preset.json | 0.2 | Vulnerability analysis |
evony-protocol-decoder.preset.json | 0.1 | AMF3 binary decoding |
evony-code-auditor.preset.json | 0.3 | AS3/bot code review |
evony-quick-reference.preset.json | 0.5 | Fast lookups |
evony-forensic-analyst.preset.json | 0.25 | Incident investigation |
evony-creative-writer.preset.json | 0.7 | Documentation |
Copy-Item "C:\Users\Admin\Downloads\Evony_Decrypted\lmstudio_presets\*.preset.json" "$env:USERPROFILE\.lmstudio\config-presets\"
| File | Purpose |
|---|---|
enhanced_kg_extractor.py | Advanced relationship extraction |
rebuild_in_place.py | In-place KG rebuild |
rebuild_to_temp.py | Temp directory rebuild |
rebuild_final.py | Final rebuild script |
rebuild_indices_full.py | Full index rebuild |
verify_indices.py | Index verification |
test_kg_save.py | KG save testing |
check_actual.py | Actual state checker |
final_status.py | Final status report |
RELATIONSHIP_PATTERNS = {
"calls": [obj.method(), func(arg), new ClassName],
"references": [assignment, return, type annotation],
"contains": [XML parent-child, nested JSON],
"uses": [imports, includes],
}
| Metric | Value |
|---|---|
| Entities | 101,853 |
| Relationships | 346,398 |
| KG File | kg_full.json (7.1 MB) |
| File | Purpose |
|---|---|
chunks_recovered.json | Recovered chunks |
chunks_fixed.json | Fixed chunks |
chunks_corrupted_backup.json | Backup of corrupted |
| Field | Value |
|---|---|
| Account Name | Siren |
[email protected] | |
| Password | SirensSoli2D |
| Server | cc2 |
| Status | Active |
| SOL Path | D:\EvonyToolKit\Macromedia\Flash Player\#SharedObjects\3HLDSEQY\localhost\evony\Siren\roboevony.exe\config.sol |
How We Test:
cd C:\Users\Admin\Downloads\Evony_Decrypted\evony_rag
# Run benchmark with natural questions
python benchmark_natural.py
# Test precision RAG
python -c "from precision_rag import PrecisionRAG; rag = PrecisionRAG(); print(rag.query('farmNPC script'))"
# Test MCP Server
python mcp_server_v2.py
Test Questions:
"food glitch script" β Expects exploit response
"farmNPC command" β Expects script command help
"SendTroops function" β Expects AS3 code explanation
"AMF3 packet decode" β Expects protocol info
How to Test:
cd C:\Users\Admin\Downloads\Evony_Decrypted\evony_bot
# Start bot server
python server.py
# Access Web UI
http://localhost:9999
Connect with Siren Account:
localhost:9999[email protected] / SirensSoli2Dcc2How to Test:
cd C:\Users\Admin\Downloads\Evony_Decrypted\BorgToolkit
# Test single login
python test_login.py
# Test account validation
python test_account_passwords.py
How to Test:
# Check model is loaded
lms ps
# Test via API
curl http://localhost:1234/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"messages":[{"role":"user","content":"What does SendTroops do?"}]}'
From Python:
import requests
resp = requests.post("http://localhost:1234/v1/chat/completions",
json={"messages": [{"role": "user", "content": "How do I exploit troop overflow?"}]})
print(resp.json()['choices'][0]['message']['content'])
| Method | Tool/Command | What It Tests |
|---|---|---|
| MCP evony.search | evony.search("query") | RAG hybrid search |
| MCP evony.answer | evony.answer("query") | LLM generation |
| MCP evony.precision | evony.precision("query") | Verified answers |
| MCP evony.feedback | Submit feedback | Feedback loop |
| MCP evony.stats | Get RAG stats | System health |
http://localhost:7860
# RAG Search
curl "http://localhost:8000/search?q=SendTroops"
# RAG Answer
curl "http://localhost:8000/answer?q=overflow%20exploit"
| Metric | Expected | Actual |
|---|---|---|
| Answered | 60%+ | 60% |
| Grounded | 70%+ | 70% |
| Confidence | 70%+ | 78% |
| OVERALL | 65%+ | 69% GOOD |
| Query | Expected Response Type |
|---|---|
| "food glitch script" | Exploit/script code |
| "SendTroops function" | AS3 code explanation |
| "AMF3 decode" | Protocol info |
| "farmNPC command" | Script command syntax |
| "troop overflow" | Exploit details |
| Query | Why It Fails |
|---|---|
| "how to play evony" | Not trained on gameplay |
| "best troops to train" | Gameplay question |
| "alliance strategy" | Not in training data |
The model was trained EXCLUSIVELY for:
| Category | Count |
|---|---|
| Total Examples | 766,822 |
| Source Code | 120,645 |
| Script-Related | 15,764 |
| ActionScript | 6,468 |
| Protocol | 3,530 |
| Verified CVEs | 1,358 |
| Overflow Exploits | 1,476 |
| Unique Script Files | 321 |
| File | Purpose | Lines |
|---|---|---|
precision_rag.py | Main precision RAG with verification, confidence, citations | 490+ |
question_formatter.py | Transforms vague questions to training format | 333 |
feedback_loop.py | User feedback collection for improvement | 180 |
reranker.py | Cross-encoder + heuristic reranking | 166 |
chroma_search.py | Optional ChromaDB vector search integration | 213 |
| File | Purpose |
|---|---|
comprehensive_benchmark.py | Full benchmark suite (features + queries) |
quick_benchmark.py | Lightweight memory-safe benchmark |
benchmark_proper.py | Reverse engineering focused benchmark |
benchmark_dataset.py | Tests using actual training data questions |
benchmark_natural.py | Natural user question benchmark |
gap_analysis.py | Identifies missing integrations |
| File | Purpose |
|---|---|
analyze_scripts.py | Analyzes script content in training data |
analyze_chunks.py | Analyzes RAG chunks for script content |
count_all_scripts.py | Comprehensive script count across all data |
| File | Purpose |
|---|---|
test_enhanced_kg.py | Knowledge graph enhancement tests |
test_rag_with_kg.py | RAG + KG integration tests |
test_kg_targeted.py | Targeted KG query tests |
test_integrated_rag.py | Full pipeline integration tests |
test_full_pipeline.py | End-to-end pipeline tests |
test_evony_queries.py | Domain-specific query tests |
test_hybrid_search.py | Hybrid search tests |
test_lmstudio_rag.py | LM Studio + RAG integration tests |
test_proper_questions.py | Training format question tests |
question_formatter.py)Purpose: Transforms vague user questions into training-compatible format
PATTERNS = {
"file_purpose": "What is the purpose of {entity} in Evony?",
"class_function": "What does the {entity} class/function do in Evony?",
"how_works": "How does {entity} work in the Evony client?",
"parameters": "What parameters does {entity} accept?",
"explain_code": "Explain this Evony code:\n```\n{code}\n```",
"script_command": "How do I use the {entity} script command in Evony?",
"exploit": "How do I exploit {entity} in Evony?",
"cve": "What CVE affects {entity}?",
"protocol": "How does the {entity} protocol/packet work?",
"write_script": "Write a script to {action}",
"overflow": "How does the {entity} overflow exploit work?",
}
SCRIPT_COMMANDS = {
'setsilence', 'echo', 'set', 'label', 'goto', 'if', 'endif', 'loop',
'endloop', 'wait', 'attack', 'farm', 'scout', 'sendmail', 'getmail',
'deleteMail', 'reinforce', 'recall', 'build', 'research', 'train',
'findNPC', 'farmNPC', 'scanMap', 'getArmyStatus', 'useItem',
}
reranker.py)Purpose: LM Studio-based relevance scoring for better retrieval
class CrossEncoderReranker:
def score_relevance(self, query: str, document: str) -> float:
"""Score 0-10 relevance using LLM"""
def rerank(self, results: List[Dict], query: str, top_k: int = 5) -> List[Dict]:
"""Rerank top candidates by cross-encoder score"""
feedback_loop.py)Purpose: Collect user feedback to improve answers
G:\evony_rag_index\user_feedback.jsonfeedback = get_feedback_collector()
feedback.add_feedback(query, answer, rating="correct", correction=None)
feedback.get_stats() # {total, correct, incorrect, partial, accuracy}
feedback.export_for_training() # Creates JSONL for fine-tuning
chroma_search.py)Purpose: Optional vector database for semantic search
G:\evony_rag_index\chroma_dbfrom evony_rag.chroma_search import get_chroma_search, CHROMA_AVAILABLE
if CHROMA_AVAILABLE:
chroma = get_chroma_search()
chroma.index_chunks(chunks) # One-time indexing
results = chroma.search("attack command", k=10)
precision_rag.py)Purpose: Maximum accuracy answer system
rag = get_precision_rag()
# Standard query
result = rag.query(question, use_cache=True, auto_format=True)
# Self-consistency (generates 3 answers, picks best)
result = rag.query_with_consensus(question, num_answers=3)
# Feedback
rag.add_feedback(query, answer, rating="correct", correction=None)
rag.get_feedback_stats()
@dataclass
class VerifiedAnswer:
question: str
answer: str
confidence: float # 0-1
citations: List[Citation]
is_grounded: bool
verification_notes: List[str]
retrieval_stats: Dict
gradio_ui.py)Purpose: Web interface with feedback buttons
http://localhost:7860
mcp_server_v2.py)Purpose: MCP tools for Claude Desktop
evony.feedback{
"name": "evony.feedback",
"description": "Submit feedback on an answer to improve the system",
"inputSchema": {
"properties": {
"question": {"type": "string"},
"answer": {"type": "string"},
"rating": {"enum": ["correct", "partial", "incorrect"]},
"correction": {"type": "string"}
}
}
}
| Tool | Purpose |
|---|---|
evony.search | Hybrid lexical+semantic search |
evony.answer | LLM-generated answer |
evony.precision | Verified answer with citations |
evony.feedback | NEW Submit feedback |
evony.open | Read source file |
evony.symbol | Find symbol |
evony.mode | Set query mode |
evony.stats | Get stats |
| Metric | Score |
|---|---|
| Answered | 6/10 (60%) |
| Grounded | 7/10 (70%) |
| Avg Confidence | 78% |
| Avg Response Time | 9.7s |
| OVERALL SCORE | 69% - GOOD |
| Category | Answered | Confidence |
|---|---|---|
| Exploits | 2/3 | 76% |
| Scripts | 2/3 | 74% |
| Source Code | 1/3 | 79% |
| Protocol | 1/1 | 73% |
food glitch script - 77% confidenceoverflow exploit troops - 70% confidencefarmNPC script command - 77% confidenceattack script example - 77% confidenceSendTroops function - 73% confidenceAMF3 packet decode - 73% confidence| Feature | Status | Time |
|---|---|---|
| Question Formatter | β Working | 780ms |
| Cross-Encoder Reranker | β Working | 130ms |
| Feedback Loop | β Working | 3ms |
| Self-Consistency | β Working | 5ms |
| ChromaDB | β Available | 2045ms |
| Component | Count |
|---|---|
| Chunks | 16,962 |
| Embeddings | 16,962 x 768 dims |
| KG Entities | 101,853 |
| KG Relationships | 346,398 |
| Cached Answers | 13+ |
G:\evony_rag_index\
βββ embeddings.npy # 99.4 MB
βββ knowledge_graph.json # KG data
βββ answer_cache.json # Cached answers
βββ user_feedback.json # Feedback data
βββ chroma_db/ # ChromaDB (optional)
C:\Users\Admin\Downloads\Evony_Decrypted\evony_rag\index\
βββ chunks.json # 16,962 chunks
precision_rag.py - Main RAG with all integrationsquestion_formatter.py - Question transformationfeedback_loop.py - Feedback collectionreranker.py - Cross-encoder rerankingchroma_search.py - ChromaDB integrationgradio_ui.py - Feedback buttonsmcp_server_v2.py - evony.feedback toolcomprehensive_benchmark.py - Full test suitebenchmark_natural.py - Natural question testsgap_analysis.py - Integration gap checker# Test these natural questions:
"troop glitch how to use?"
"food glitch script"
"farmNPC script command"
"attack script example"
"AMF3 packet decode"
C:\Users\Admin\Downloads\Evony_Decrypted\evony_rag\
βββ precision_rag.py # β
UPDATED - Main RAG system
βββ question_formatter.py # β
NEW - Question transformation
βββ feedback_loop.py # β
NEW - User feedback
βββ reranker.py # β
UPDATED - Cross-encoder added
βββ chroma_search.py # β
NEW - ChromaDB integration
βββ gradio_ui.py # β
UPDATED - Feedback buttons
βββ mcp_server_v2.py # β
UPDATED - evony.feedback tool
βββ gap_analysis.py # β
NEW - Integration checker
βββ comprehensive_benchmark.py # β
NEW - Full benchmark
βββ quick_benchmark.py # β
NEW - Lightweight benchmark
βββ benchmark_natural.py # β
NEW - Natural questions
βββ analyze_scripts.py # β
NEW - Script analysis
βββ analyze_chunks.py # β
NEW - Chunk analysis
βββ count_all_scripts.py # β
NEW - Script counter
Hey Claude!
MASSIVE RAG IMPROVEMENTS since your last audit:
1. QUESTION FORMATTER
- Transforms vague questions to training format
- 15 patterns including exploits, CVEs, scripts
- Recognizes 20+ script commands
2. CROSS-ENCODER RERANKING
- LM Studio-based relevance scoring
- Heuristic boosting for exact matches
- Integrated in precision_rag.py
3. FEEDBACK LOOP
- Collect correct/incorrect/partial ratings
- Export corrections for fine-tuning
- Integrated in precision_rag, gradio_ui, mcp_server
4. CHROMADB INTEGRATION
- Optional vector database
- Non-destructive addition
- Self-hosted, no external services
5. SELF-CONSISTENCY
- Multi-answer consensus
- query_with_consensus(question, num_answers=3)
6. MCP SERVER
- NEW evony.feedback tool
- 8 total tools available
7. GRADIO UI
- Feedback buttons added
- Correction input for wrong answers
8. BENCHMARKING
- 5 benchmark scripts created
- Natural question benchmark: 69% GOOD
- All 5 features working (100%)
MODEL PURPOSE CLARIFICATION:
- Trained for reverse engineering, scripts, exploits
- NOT trained on gameplay
- 766,822 examples, 15,764 script-related
- Flash 10 era (2009-2018)
BENCHMARK RESULTS:
- Answer Rate: 60%
- Grounded: 70%
- Avg Confidence: 78%
- Features Working: 100%
AUDIT REQUEST:
1. Review new RAG features
2. Test question formatter patterns
3. Verify feedback loop works
4. Check benchmark accuracy
5. Suggest further improvements
Currently loaded: F16 (evony-7b-3800-f16) | 15.24 GB | Ready
- Windsurf
Purpose: Search 16,963 chunks using BM25 lexical + semantic embedding fusion
MCP Call:
evony.search(query="SendTroops function", k=5)
Parameters:
| Param | Type | Default | Description |
|---|---|---|---|
| query | string | required | Search query |
| k | int | 10 | Number of results |
Returns:
{
"file": "scripts/scripts.txt",
"lines": "687-702",
"category": "scripts",
"score": 0.016,
"snippet": "actual code snippet..."
}
Example Queries:
"SendTroops function" - Find troop sending code"AMF3 decode" - Protocol decoding"food glitch" - Exploit scripts"farmNPC command" - Bot script commandsPurpose: Get RAG system health and statistics
MCP Call:
evony.stats()
Returns:
{
"chunks": 16963,
"symbols": 55871,
"mode": "research",
"modes_available": ["research", "forensics", "full_access"]
}
Purpose: Change access level for different use cases
MCP Call:
evony.mode(mode="full_access")
Available Modes:
| Mode | Description | Access Level |
|---|---|---|
research | Educational analysis | Standard |
forensics | Security research | Elevated |
full_access | Complete access | Full |
Purpose: Get answers with confidence scores and citations
Python Usage:
from evony_rag.precision_rag import PrecisionRAG
rag = PrecisionRAG()
result = rag.query("What is SendTroops?")
print(result["answer"])
print(result["confidence"])
print(result["citations"])
Returns:
{
"answer": "SendTroops is a ArmyCommands function...",
"confidence": 0.85,
"citations": ["ArmyCommands.as:45-60"],
"grounded": true
}
Purpose: Transform vague questions to training-compatible format
Python Usage:
from evony_rag.question_formatter import EvonyQuestionFormatter
fmt = EvonyQuestionFormatter()
formatted = fmt.format("food glitch")
# Returns: "How do I exploit food glitch in Evony?"
Pattern Types:
| Input Pattern | Transformation |
|---|---|
"SendTroops" | "What does the SendTroops class/function do?" |
"farmNPC" | "How do I use the farmNPC script command?" |
"food glitch" | "How do I exploit food glitch in Evony?" |
"AMF3" | "How does the AMF3 protocol/packet work?" |
Purpose: Collect feedback to improve future answers
Python Usage:
from evony_rag.feedback_loop import get_feedback_collector
fc = get_feedback_collector()
# Add feedback
fc.add_feedback(
query="What is SendTroops?",
answer="SendTroops sends troops...",
rating="correct", # or "incorrect", "partial"
correction=None, # provide if incorrect
confidence=0.85
)
# Get stats
stats = fc.get_stats()
# {"total": 10, "correct": 8, "incorrect": 1, "partial": 1, "accuracy": 0.85}
# Export for training
fc.export_for_training()
Purpose: Rerank search results by relevance
Python Usage:
from evony_rag.reranker import ResultReranker
rr = ResultReranker()
reranked = rr.rerank(results, query="SendTroops", top_k=5)
Boost Factors:
| Factor | Boost |
|---|---|
| Exact match | +0.3 |
| Definition | +0.2 |
| Public API | +0.15 |
| Documentation | +0.1 |
| .as file | +0.1 |
Purpose: Extract all strings from decompiled client code
Python Usage:
from evony_rte.mcp_server import handle_client_strings
result = handle_client_strings({"filter": "http", "min_length": 10})
print(f"Found {result['total']} strings")
Parameters:
| Param | Type | Default | Description |
|---|---|---|---|
| filter | string | "" | Filter pattern |
| min_length | int | 4 | Minimum string length |
Returns: 500 strings from AS3_Scripts directory
Purpose: Search decompiled AS3 code for functions/variables
Python Usage:
from evony_rte.mcp_server import handle_client_search
result = handle_client_search({"query": "function", "type": "all"})
print(f"Found {result['total']} matches")
Parameters:
| Param | Type | Default | Description |
|---|---|---|---|
| query | string | required | Search query |
| type | string | "all" | function/class/variable/all |
Purpose: List all known exploits with status
Python Usage:
from evony_rte.mcp_server import handle_exploit_list
result = handle_exploit_list({"category": "all"})
print(f"Found {len(result['exploits'])} exploits")
Categories: overflow, race, injection, bypass, all
Purpose: Check status of all reverse engineering tools
Python Usage:
from evony_rte.mcp_server import handle_advanced_tools_status
result = handle_advanced_tools_status({})
print(f"Installed: {result['installed']}/{result['total']}")
Returns (9/9 installed):
| Tool | Status | Description |
|---|---|---|
| zeek | β | Network security monitor |
| ngrep | β | Network pattern grep |
| tcpflow | β | TCP stream extraction |
| scapy | β | Packet crafting |
| ghidra | β | NSA RE framework |
| radare2 | β | RE framework |
| swfmill | β | SWF to XML |
| swftools | β | SWF manipulation |
| ffdec | β | Flash decompiler |
Purpose: Capture and analyze network traffic
Command Line:
# Capture to file
tshark -i 1 -w capture.pcap -f "port 80"
# Read and filter
tshark -r capture.pcap -Y "http"
# Check version
tshark -v
Status: β v4.6.2 installed and running (PID 24972)
Purpose: Decompile and analyze SWF files
Command Line:
# CLI decompile
"C:\Program Files (x86)\FFDec\ffdec-cli.exe" -export as3 output/ file.swf
# Export all scripts
ffdec-cli -export script output/ AutoEvony.swf
GUI: Already running (PID 26616)
Location: C:\Program Files (x86)\FFDec\
Purpose: Advanced reverse engineering of binaries
Command Line:
# Headless analysis
C:\ProgramData\chocolatey\lib\ghidra\tools\ghidra_12.0_PUBLIC\support\analyzeHeadless.bat project_dir project_name -import file.exe -postScript analysis.py
GUI: Already running (Java PIDs 30208, 31532, 30544)
Location: C:\ProgramData\chocolatey\lib\ghidra\tools\ghidra_12.0_PUBLIC\
Purpose: Query the fine-tuned Evony model
HTTP API:
curl -X POST http://localhost:1234/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model":"evony-7b-3800","messages":[{"role":"user","content":"What is SendTroops?"}]}'
Python:
import requests
resp = requests.post("http://localhost:1234/v1/chat/completions",
json={
"model": "evony-7b-3800",
"messages": [{"role": "user", "content": "What is SendTroops?"}],
"max_tokens": 100
})
print(resp.json()["choices"][0]["message"]["content"])
Status: β 40+ models available, evony-7b-3800 loaded
| Tool | Usage | Description |
|---|---|---|
evony.search(query, k) | Search chunks | Hybrid BM25+semantic |
evony.stats() | Get stats | Chunks, symbols, mode |
evony.mode(mode) | Set mode | research/forensics/full_access |
# RAG
from evony_rag.precision_rag import PrecisionRAG
from evony_rag.hybrid_search import get_hybrid_search
from evony_rag.question_formatter import EvonyQuestionFormatter
from evony_rag.feedback_loop import get_feedback_collector
from evony_rag.reranker import ResultReranker
# RTE
from evony_rte.mcp_server import (
handle_client_strings,
handle_client_search,
handle_exploit_list,
handle_advanced_tools_status
)
from evony_rte.advanced_re_tools import get_all_advanced_tools_status
| Test | Status | Evidence |
|---|---|---|
| evony.stats | β PASS | 16,963 chunks |
| evony.search | β PASS | Returns results |
| evony.mode | β PASS | Switches modes |
| LM Studio | β PASS | Real answers |
| Tshark | β PASS | v4.6.2 |
| Wireshark | β PASS | Running |
| FFDec | β PASS | Running |
| Ghidra | β PASS | Running |
| client_strings | β PASS | 500 strings |
| client_search | β PASS | 50 results |
| exploit_list | β PASS | 5 exploits |
| advanced_tools | β PASS | 9/9 tools |
| FeedbackCollector | β PASS | Working |
| Reranker | β PASS | Working |
PASS RATE: 14/14 (100%)
Last Updated: January 11, 2026 06:16 UTC-07:00
Windsurf Cascade - Primary Programmer