LearnNewsExamplesServices
Frontmatter
id8324
title[Neural Link] Generalize Property Access to InstanceService
stateClosed
labels
enhancementairefactoring
assigneestobiu
createdAtJan 4, 2026, 8:20 PM
updatedAtJan 4, 2026, 8:29 PM
githubUrlhttps://github.com/neomjs/neo/issues/8324
authortobiu
commentsCount1
parentIssue8169
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJan 4, 2026, 8:29 PM

[Neural Link] Generalize Property Access to InstanceService

Closed v11.18.0 enhancementairefactoring
tobiu
tobiu commented on Jan 4, 2026, 8:20 PM

Proposed by Gemini 3 Pro.

Goal: Generalize the get_component_property and set_component_property tools to work with any Neo.core.Base instance (Stores, Controllers, Managers), not just Components.

Tasks:

  1. Create src/ai/client/InstanceService.mjs.
  2. Implement getInstanceProperty and setInstanceProperty using Neo.get() instead of Neo.getComponent().
  3. Update src/ai/Client.mjs to include the new service.
  4. Update ai/mcp/server/neural-link/services/toolService.mjs mappings.
  5. Update ai/mcp/server/neural-link/openapi.yaml to rename tools and update schema.
  6. Remove the old get_component_property and set_component_property implementations from ComponentService.mjs.

Rationale: AI agents need to inspect non-visual instances (like data stores or state controllers) to fully understand and manipulate the application state. Restricting property access to Components is an unnecessary limitation.

tobiu added the enhancement label on Jan 4, 2026, 8:20 PM
tobiu added the ai label on Jan 4, 2026, 8:20 PM
tobiu added the refactoring label on Jan 4, 2026, 8:20 PM
tobiu added parent issue #8169 on Jan 4, 2026, 8:20 PM
tobiu assigned to @tobiu on Jan 4, 2026, 8:20 PM
tobiu referenced in commit 55ffe15 - "Refactor: Generalize Property Access to InstanceService (#8324)" on Jan 4, 2026, 8:28 PM
tobiu
tobiu Jan 4, 2026, 8:29 PM

Input from Gemini 3 Pro:

✦ I have successfully refactored the property access tools to be generic and support any Neo instance.

Changes Implemented:

  1. New Service: Created src/ai/client/InstanceService.mjs and ai/mcp/server/neural-link/services/InstanceService.mjs.
  2. Renamed Tools:
    • get_component_property -> get_instance_property
    • set_component_property -> set_instance_property
  3. Expanded Scope: The tools now use Neo.get(id) instead of Neo.getComponent(id), allowing access to Stores, Controllers, Managers, and any other Neo.core.Base instance.
  4. Cleanup: Removed the old component-specific implementations from ComponentService.
  5. API Update: Updated openapi.yaml to reflect the new tool names, descriptions, and schema references (e.g., GetInstancePropertyRequest).

Commit: 55ffe15d0

Next Steps:

  • Restart the Neural Link server to apply the changes.
  • Verify the new get_instance_property tool with a non-component instance (e.g., a Store).
tobiu closed this issue on Jan 4, 2026, 8:29 PM