eph-context
Integrates with VS Code via GitHub Copilot's MCP support to provide EPH-specific context, design records, and methodology, helping AI assistants write correct code for EPH data analysis.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@eph-context Write R code for EPH household weights using official design"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
eph-context
Que la IA escriba tu código de EPH sin inventar lo que no existe
Los modelos de IA alucinan variables de la EPH que no existen, aplican mal los ponderadores y se olvidan del panel rotante. eph-context le da al modelo los diseños de registro oficiales del INDEC y las reglas metodológicas antes de que escriba una línea. Resultado: código correcto, sin inventos.
¿Qué herramienta usás?
Herramienta | Instalación | Sección |
ChatGPT (web, sin instalar nada) | Ninguna | |
Claude Desktop | Muy simple | |
Cursor | Muy simple | |
VS Code | Muy simple | |
Claude Code (terminal) | Para desarrolladores |
Related MCP server: enaho-mcp
ChatGPT — sin instalar nada
La opción más simple. Funciona directamente en chatgpt.com creando un GPT personalizado con el conocimiento de la EPH incluido.
Qué vas a necesitar
Una cuenta de ChatGPT Plus (pago) — necesaria para subir archivos de conocimiento a un GPT personalizado
Los archivos de la carpeta
assets/de este repositorio
Pasos
1. Descargá los archivos de conocimiento
Andá a la página principal del repositorio en GitHub, hacé clic en el botón verde Code → Download ZIP y descomprimí el archivo en tu computadora.
2. Creá un GPT personalizado
En chatgpt.com:
Hacé clic en tu nombre (abajo a la izquierda) → My GPTs → Create a GPT
En la pestaña Configure, completá:
Name:
Asistente EPH INDECInstructions: copiá y pegá todo el contenido del archivo
gpt_instructions.mdque está en este repositorio
3. Subí los archivos de conocimiento
En la misma pantalla de configuración, en la sección Knowledge, hacé clic en Upload files y subí todos los archivos .md de la carpeta assets/ (design, methodology, classifiers, tools).
4. Guardá y empezá a usarlo
Hacé clic en Save (arriba a la derecha) y listo. Podés empezar a preguntarle sobre la EPH o pedirle que te escriba código.
Nota: Para subir archivos de conocimiento necesitás ChatGPT Plus (pago). Con la versión gratuita podés pegar el contenido de los archivos directamente en el chat cuando lo necesites.
Claude Desktop
Claude Desktop es la aplicación de escritorio de Anthropic. Si no la tenés, descargala desde claude.ai/download.
Lo que vas a necesitar instalar primero: uv
uv es una herramienta que maneja las dependencias de Python. Sin ella no va a funcionar.
En Mac o Linux, abrí la Terminal y pegá:
curl -LsSf https://astral.sh/uv/install.sh | shEn Windows, abrí PowerShell y pegá:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"Cerrá y volvé a abrir la terminal después de instalar.
Pasos
1. Descargá este repositorio
Si tenés git instalado, en la terminal:
git clone https://github.com/matias-denatale/eph-context.gitSi no tenés git, descargá el ZIP desde GitHub (botón verde Code → Download ZIP) y descomprimilo donde quieras. Guardá la ruta de la carpeta — la vas a necesitar.
2. Abrí el archivo de configuración de Claude Desktop
Andá a Claude Desktop → menú Claude (arriba) → Settings → Developer → Edit Config.
Se va a abrir un archivo claude_desktop_config.json. Si está vacío, pegá esto directamente:
{
"mcpServers": {
"eph": {
"command": "uv",
"args": [
"--directory",
"/ruta/a/eph-context",
"run",
"server.py"
]
}
}
}Si ya tiene contenido, agregá solo la parte de "eph": { ... } dentro de "mcpServers".
3. Reemplazá la ruta
Cambiá /ruta/a/eph-context por la ruta real donde descomprimiste el repositorio.
Mac/Linux: algo como
/Users/tu-nombre/eph-contextWindows: algo como
C:\\Users\\tu-nombre\\eph-context(con doble barra invertida)
4. Guardá y reiniciá Claude Desktop
Cerrá y volvé a abrir Claude Desktop. Las herramientas EPH van a aparecer disponibles — las podés ver haciendo clic en el ícono de herramientas (🔧) en el chat.
Cursor
Cursor es un IDE basado en VS Code con IA integrada. Si no lo tenés, descargalo desde cursor.com.
Necesitás tener uv instalado (ver instrucciones en la sección de Claude Desktop).
Pasos
1. Descargá este repositorio (igual que en Claude Desktop, paso 1)
2. Abrí la configuración de MCP en Cursor
Cursor → Settings → Cursor Settings → MCP → Add new MCP server
O bien editá el archivo ~/.cursor/mcp.json directamente y agregá:
{
"mcpServers": {
"eph": {
"command": "uv",
"args": [
"--directory",
"/ruta/a/eph-context",
"run",
"server.py"
]
}
}
}3. Reemplazá la ruta y reiniciá Cursor
VS Code
Necesitás la extensión GitHub Copilot o Continue con soporte MCP.
Necesitás tener uv instalado (ver instrucciones en la sección de Claude Desktop).
Pasos
1. Descargá este repositorio (igual que en Claude Desktop, paso 1)
2. Editá el archivo de configuración MCP
Creá o editá .vscode/mcp.json en tu proyecto:
{
"servers": {
"eph": {
"type": "stdio",
"command": "uv",
"args": [
"--directory",
"/ruta/a/eph-context",
"run",
"server.py"
]
}
}
}3. Reemplazá la ruta y reiniciá VS Code
Claude Code CLI
Para usuarios del CLI de Claude Code en terminal.
1. Cloná el repositorio en tu carpeta de skills:
git clone https://github.com/matias-denatale/eph-context.git ~/.claude/skills/eph2. Agregá esta línea a tu ~/.claude/CLAUDE.md en la tabla de skills:
| EPH microdata, usu_hogar, usu_individual, scripts R/Python con EPH | `~/.claude/skills/eph/SKILL.md` |La skill se activa automáticamente cuando Claude Code detecta consultas sobre EPH, variables como CODUSU, PONDERA, ESTADO, etc.
¿Qué sabe hacer?
Una vez instalado, podés pedirle cosas como:
"Calculá la tasa de desocupación para el 2do trimestre de 2024 con R"
"¿Qué es el panel rotante y cómo afecta el análisis longitudinal?"
"Escribime un script en Python para calcular informalidad laboral"
"¿Cómo mergeo las bases de hogar e individual?"
"¿Qué variables cambaron en el 4T2023?"
El modelo siempre consulta los diseños de registro y la metodología oficial antes de responder. No adivina, no improvisa.
Ejemplo de sesión
Usuario: Calculá la tasa de desocupación para el 4T2024 con R.
El modelo (internamente):
eph_setup()→ recibe workflow obligatorio + reglas críticasget_design_record("31_aglomerados_post")→ variablesESTADO,PONDERAy sus categorías exactasget_methodology("indicadores_mercado_laboral")→ fórmula oficial INDEC
Respuesta del modelo:
library(eph)
base <- get_microdata(year = 2024, trimester = 4, type = "individual")
base |>
summarise(
desocupacion = sum(PONDERA[ESTADO == 2]) / sum(PONDERA[ESTADO %in% c(1, 2)]) * 100
)Sin inventar nombres de variables. Sin ponderadores incorrectos. Sin mezclar períodos pre/post 4T2023.
¿Qué incluye?
Contenido | Qué es |
Diseños de registro | Variables, categorías y codificaciones para EPH Continua y Total Urbano, antes y después del 4T2023 |
Reglas metodológicas | Ponderadores, panel rotante, quiebre de serie, informalidad, indicadores de mercado de trabajo |
Documentación de packages | Paquete |
Clasificador CNO 2001 | Clasificador Nacional de Ocupaciones completo (5 dígitos) |
Agradecimientos
Diego Kozlowski — creador del paquete
ephpara R
Autor
Desarrollado por Matías De Natale.
Licencia
MIT. Usalo, modificálo, compartilo. Si lo mejorás, mandá un PR.
Available Tools
6 toolseph_setupA
CALL THIS FIRST — before writing any code or referencing any variable.
Returns the mandatory workflow, critical rules, and available topics. This is step 1 of every EPH task. No exceptions.
After calling this, proceed to:
get_design_record() → exact variable names for the dataset
get_package_docs() → correct function signatures for R or Python
get_methodology() → weighting rules, rate formulas, indicator definitions
Inputs: no named parameters.
get_classifiersA
Returns the complete CNO 2001 (Clasificador Nacional de Ocupaciones).
Call eph_setup() first if you have not already. Use this to correctly interpret or recode occupation variables (PP04D_COD, P47T). Includes all 5-digit codes, descriptions, and qualification categories.
Pass filter to get only matching lines (case-insensitive substring match).
Inputs: filter. Returns: result
get_design_recordA
Returns the OFFICIAL variable dictionary for EPH microdata files.
Call eph_setup() first if you have not already. Call this BEFORE writing any code that references variable names or category codes. Do NOT use variable names from memory — they change between periods.
tipo values: "31_aglomerados_pre" — EPH 31 aglomerados urbanos, quarters BEFORE 4T2023 "31_aglomerados_post" — EPH 31 aglomerados urbanos, FROM 4T2023 onward (redesigned variables) "total_urbano_pre" — EPH Total Urbano, before 4T2023 "total_urbano_post" — EPH Total Urbano, from 4T2023 onward
If the user has not specified the period, ASK before calling this tool.
Inputs: tipo (required). Returns: result
get_methodologyA
Returns official EPH methodological documentation for a specific topic.
Call eph_setup() first if you have not already. Call this BEFORE computing rates, applying weights, or building indicators.
tema values: "que_es_la_eph" — survey overview, periodicity, geographic coverage "panel_rotante" — rotating panel design, cohort tracking across waves "ponderadores" — PONDERA / PONDIH / PONDIIO: which to use and when "indicadores_mercado_laboral" — unemployment and employment rate formulas (INDEC official) "informalidad_laboral" — informal employment classification rules "quiebre_serie_4t2023" — series break details, what changed, how to handle it "eph_continua_vs_total_urbano" — coverage and methodological differences between variants
Inputs: tema (required). Returns: result
get_package_docsA
Returns the OFFICIAL API reference for the EPH data package.
Call eph_setup() first if you have not already. Call this BEFORE writing any import statement or function call. Do NOT use function names or argument names from memory — they may be wrong.
lang values:
"r" — eph R package: get_microdata(), organize_labels(), calculate_tabulates()
"python" — pyeph library: download(), organize(), LaborMarket, Poverty classes
Inputs: lang (required). Returns: result
search_variableA
Search a variable by partial name or description across all design records.
Inputs: name (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool has a distinct purpose: setup, classifiers, design record, methodology, package docs, variable search. No overlaps.
Most tools follow get_noun pattern; eph_setup and search_variable deviate but are still clear and recognizable.
6 tools is well-scoped for a context server covering EPH survey setup and reference materials.
Covers all essential context aspects (setup, codes, variables, methods, docs, search). Minor gap: no direct tool for period validation but covered by setup instructions.
Maintenance
Related MCP Connectors
Argentina's official public data (INDEC, BCRA, 38 portals): search, read tables, cited answers.
Argentina's official statistics (INDEC): inflation, wages, poverty, trade, population. No signup.
Valid and reliable data engineering and statistical analysis without hallucinations.
Official Mexican data for AI agents: CURP, RFC, CFDI, postal codes, phone, SPEI/CEP, DOF, geocoding.
Related MCP Servers
- AlicenseAqualityDmaintenanceMCP server for the ESRU-EMOVI 2023 social mobility survey in Mexico. Enables AI assistants to query weighted statistics, transition matrices, and explore variables from the survey using natural language.11MIT
- AlicenseAqualityCmaintenanceMCP server for ENAHO (Peru's national household survey) microdata. Enables discovery, download, merging, and complex-survey statistical estimation of official poverty and income indicators, with report generation.321MIT
- AlicenseNot gradedqualityCmaintenanceArgentina's official public data (INDEC, BCRA, 38 portals) in your AI assistant: search datasets, read tables, get answers with the official source. Free key.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents and analysts to query UN CEPALSTAT indicators through MCP by resolving natural-language requests into statistically valid indicators and retrieving clean, decoded data with anti-hallucination safeguards.MIT