Skip to content

Divyansh3021/ninelayer-experiments

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

NineLayer Experiments

Real-world comparisons showing the difference between using Claude with and without NineLayer MCP — an MCP Search API that returns structured, authority-aware evidence packets instead of raw links.

The Problem

AI coding agents often produce outdated code because their training data has a cutoff date. When frameworks like LangChain release breaking API changes, agents without live context will generate code that doesn't work. Standard search tools (Tavily, Exa) return messy HTML and SEO-ranked links — forcing the agent to guess what to trust.

The Solution

NineLayer MCP performs a deep web search before the agent writes code, returning typed evidence packets classified by source type (official_docs, github_repo, community_evidence), authority tier, and freshness. The agent knows exactly what kind of source it's reading before it writes a single line.

Results at a Glance

Without NineLayer With NineLayer
LangChain API Deprecated AgentExecutor + create_openai_tools_agent Current langchain.agents.create_agent (v1)
Code Quality Verbose, legacy patterns Clean, modern API
Lines of Code 94 83
Will It Run? Requires older langchain versions Works with latest langchain

Experiments

# Experiment Description
01 LangChain Conversational Agent Build a tool-using agent with calculator and web search

How to Reproduce

Each experiment folder contains:

  • without-ninelayer/ — Code generated by Claude without live context
  • with-ninelayer/ — Code generated by Claude with NineLayer MCP providing latest docs
  • README.md — Detailed comparison and reproduction steps

Setup

Prerequisites

  • Python 3.10+
  • An OpenAI API key
  • Claude Code (for reproducing with/without NineLayer)
  • NineLayer MCP configured in your agent

Configure NineLayer MCP

Add NineLayer to your Claude Code MCP configuration:

claude mcp add ninelayer \
  --transport http \
  https://mcp.ninelayer.in/mcp/ \
  -H "Authorization: Bearer nl_..."

Or manually in your MCP config:

{
  "mcpServers": {
    "ninelayer": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/client"],
      "url": "https://mcp.ninelayer.in/mcp/",
      "headers": {
        "Authorization": "Bearer nl_YOUR_TOKEN"
      }
    }
  }
}

Get your API token from the NineLayer dashboard. Free 7-day Pro trial, then $5/month for 3,000 Deep Searches.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages