Skip to content

MCP: find_text ignores its query; stylesmanager set returns the whole 255-style table #3011

Closed

Description

@cdwilson127

Description

Two MCP (agent interface) problems found while driving CADCraft from an MCP client.

1. find_text ignores its query. It returns the same list of texts whatever query string is given, so it cannot be used to find a word. Workaround: an AutoLISP loop over (ssget "X" '((0 . "TEXT,MTEXT"))) with wcmatch.

2. stylesmanager with action: "set" returns the whole table. Changing one style (style: {name: "Color_13", lineweight: 0.3}) returns all 255 styles of the CTB, about 25 kB of JSON, for every change. Returning only the changed style would keep agent context small.

Also seen, already tracked: save reports a timeout although the file is written (#1078).

Related: #1039 (agent interface contract, output size).

Version

CADCraft 0.19.0 (227e3c3), Windows 11.

Activity

  1. ticket-craft commented on Nov 10, 2026

    @ticket-craft

    Thanks! This ticket describes several separate problems:

    • findtext ignores its query
    • stylesmanager set returns the whole 255-style table

    It helps a lot if each one has its own ticket, so they can be tracked and fixed separately.

    Possibly related: #1039 and #335.

  2. cdwilson127 commented on Nov 10, 2026

    @cdwilson127
    Author

    I'm taking this one: a PR for both parts follows shortly. It can be split into two if you prefer separate tickets, since the changes touch different files.

  3. dotCooCoo commented on Nov 20, 2026

    @dotCooCoo
    Contributor

    Fixed in #3026, merged 2026-11-20. It is expected in v0.21.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions