Project structure of: openai/automated-interpretability
explain_puzzles.pyAI-powered puzzle solver.generate_and_score_explanation.pyNeuron data explanation generation and simulation.generate_and_score_token_look_up_table_explanation.pyGenerate and score token explanation table.
activation_records.pyActivation records management and analysis.activations.pyNeuron activation record slicing and processing.token_connections.pyReads token-activation data from Azure, formats results.
api_client.pyAsync OpenAI API client with error handling and exponential backoffazure.pyAzure format converter for input URLs.calibrated_simulator.pyCalibrated Neuron Simulator Improvementsexplainer.pyNeuron explainer AI model for generating explanations using API calls and prompts.explanations.pyNeuron explanation, asynchronous loading, sorted indices.prompt_builder.pyPromptBuilder: Format messages, build prompts with GPT-4 encoding.puzzles.pyPuzzle class for ground truth and false explanations.scoring.pyScoring function for neuron evaluations using correlation & R-squared.simulator.pyNeuron simulator: improved initialization, API calls, prompt formats.test_explainer.pyTest neuron explainer with event loop, GPT-4, and Harmony V4.test_simulator.pyTest script for neuron accuracy in neural networks, text-davinci-003 model.token_space_few_shot_examples.pyFew-shot medical/scientific token class for neuron explainers.
__init__.pyImports FastDataclass functions and sets all.fast_dataclasses.pyEfficient dataclasses with limited validation using orjson.test_fast_dataclasses.pyTests FastDataclass functionality and error handling.
README.mdNeuron simulation code for explanation generationsetup.pySetup script for neuron_explainer package
server.pyStarts Flask server, imports libs, loads JSON data
README.mdNeuron viewer website with local development supportApp.jsxSets up routing with CSS, Feed import.feed.jsxNeuron-Viewer: Display welcome or neuron info based on selection.heatmapGrid.tsxHeatmap grid for TokenAndActivation objects.index.jsxSetup React app with performance measurementinterpAPI.tsRetrieves top-connected neurons and layer pairs using JSON loading.datasetList.jsxVisualize and analyze neuron activation datasets.explanation.jsxNeuron viewer: component for loading, toggling sequencesindex.jsImporting components for application use.similarNeurons.jsxFetch and display neuron info, organized visually with loading animation.topTokens.jsxInteractive token display with red text and tooltips.
reportWebVitals.jsMeasures web vitals with callback function.simulationHeatmap.tsxVisualizes matching sequences in heatmaps, rendering each simulation.tokenHeatmap.tsxVisualize token activations as heatmap with customizable colors and boundaries.types.tsColor interpolation and normalization functions.utils.tsMemoize async, get query params utilitieswelcome.tsxNeuronForm component, hooks, predefined neurons, random selection.
tailwind.config.jsTailwind CSS config with source content and empty extend/plugins.
README.mdNeuron explanation tools for language models with datasets and fixes.