Frontmatter
| id | 8280 |
| title | [Neural Link] Feature: Tool inspect_class |
| state | Closed |
| labels | enhancementai |
| assignees | tobiu |
| createdAt | Jan 1, 2026, 8:17 PM |
| updatedAt | Jan 2, 2026, 12:46 AM |
| githubUrl | https://github.com/neomjs/neo/issues/8280 |
| author | tobiu |
| commentsCount | 1 |
| parentIssue | 8169 |
| subIssues | [] |
| subIssuesCompleted | 0 |
| subIssuesTotal | 0 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Jan 2, 2026, 12:46 AM |
[Neural Link] Feature: Tool inspect_class
tobiu assigned to @tobiu on Jan 1, 2026, 8:18 PM
tobiu added parent issue #8169 on Jan 1, 2026, 8:19 PM

tobiu
Jan 2, 2026, 12:45 AM
Input from Gemini 3 pro:
✦ Implemented
inspect_classtool for Neural Link.Scope & Architecture Refinement
We refined the goal from a simple "JSON schema" to a "Rich Class Blueprint". Instead of parsing source files (which misses inherited logic), we leverage the runtime knowledge:
ctor.config: The authoritative source for merged default values and config existence (afterNeo.setupClasshas run).ctor.configDescriptors: The source for config metadata (e.g.,merge: 'shallow',isEqual).prototype: The source for active methods and mixins.Implementation Details
The tool provides a "God Mode" view of a class, answering "What can this do?" and "How does it react?".
1. Rich Config Schema
Configs are not just values. The output now includes:
- Value: The resolved default value.
- Meta: Descriptor properties (if present).
- Hooks: Explicitly lists active reactive hooks (
beforeSet,afterSet,beforeGet) found on the prototype. This reveals the reactivity map of the component.2. Cleaned Public API
The
methodslist is filtered to reduce noise:
- Excluded: Internal lifecycle hooks (
construct,init,onConstructed), constructors, and reactive config hooks (which are now categorized underconfigs).- Included: Actionable public methods (
destroy,toJSON,set, etc.).3. Hierarchy & Mixins
- Returns the full
ntypeChainand resolvedmixinslist.This distinguishes
inspect_class(Blueprint/Manual) fromtoJSON(Runtime State), providing agents with the deep understanding needed for complex tasks.
tobiu closed this issue on Jan 2, 2026, 12:46 AM
Implement
inspect_classto allow AI agents to introspect the schema of a class at runtime.Requirements:
className(string).Neo.ns().Why: This allows the agent to "read the manual" for the specific app instance it is connected to, ensuring it sends valid data and understands the capabilities of custom components not in its training data.