Skip to content

Conversation

@Harsh9485
Copy link
Contributor

@Harsh9485 Harsh9485 commented Aug 21, 2025

Closes #239

/claim #239

Description

video :- https://www.loom.com/share/d1d1d54d48bc45c4a48271ca9a387a88?sid=933e250d-78f8-4a7f-9745-0e908c0ee4d9

Type of Change

  • New module
  • Bug fix
  • Feature/enhancement
  • Documentation
  • Other

Module Information

Path: registry/coder/modules/aider
New version: v1.0.0
Breaking change: [ ] Yes [x] No

Testing & Validation

  • Tests pass (bun test)
  • Code formatted (bun run fmt)
  • Changes tested locally

Related Issues

@Harsh9485
Copy link
Contributor Author

@matifali @DevelopmentCats, most of the module works fine, but now I’m implementing MCP configuration and task prompts with active chatting.

Screenshot 2025-08-21 202353

The --message flag disables chat mode, runs only the prompt, and then exits the program. I’m trying to find a way to keep chat mode running inside the module.

@matifali
Copy link
Member

@Harsh9485, I think we should run in chat mode using AgentAPI by default, but provide the option to use message mode and disable AgentAPI (i.e., Coder Tasks) integration if a user wants to run in that mode.

@Harsh9485
Copy link
Contributor Author

@Harsh9485, I think we should run in chat mode using AgentAPI by default, but provide the option to use message mode and disable AgentAPI (i.e., Coder Tasks) integration if a user wants to run in that mode.

So should I give the user three options:
1 Empty prompt (works fine),
2 Task prompt,
3 Run the Aider module with a task prompt (runs only once and disables AgentAPI)

@matifali
Copy link
Member

So should I give the user three options:
1 Empty prompt (works fine),
2 Task prompt,
3 Run the Aider module with a task prompt (runs only once and disables AgentAPI)

Yes @Harsh9485

@Harsh9485
Copy link
Contributor Author

@matifali, unfortunately we can’t run interactive mode with the --message flag. What should I do now?

@Harsh9485
Copy link
Contributor Author

@matifali @DevelopmentCats. PR ready to review.

@Harsh9485
Copy link
Contributor Author

@matifali @DevelopmentCats, I have added the MCP server configuration.

@Harsh9485
Copy link
Contributor Author

@matifali @DevelopmentCats, let me know if you need any changes in the code.

@Harsh9485
Copy link
Contributor Author

@DevelopmentCats, did we fix the agentapi -l flag error?

@DevelopmentCats
Copy link
Contributor

@DevelopmentCats, did we fix the agentapi -l flag error?

What issue where you getting with the -I flag?

@Harsh9485
Copy link
Contributor Author

I mentioned the error in this Discord thread. https://discord.com/channels/747933592273027093/1425453418998403169

@Harsh9485
Copy link
Contributor Author

agentapi without task prompt 🟢

Screenshot 2025-10-18 095302 Screenshot 2025-10-18 095325

@Harsh9485
Copy link
Contributor Author

I'm running into that flag error, and that is the full error message :

`
Provider: google
Module: gemini

API key provided !
Starting in directory: /home/coder
Using Initial Prompt to Start agentapi with Task Prompt
Error: unknown shorthand flag: 'I' in -I=
You are a helpful Coding assistant. Aim to autonomously investigate
hey
Usage:
agentapi server [agent] [flags]

Flags:
-a, --allowed-hosts strings HTTP allowed hosts (hostnames only, no ports). Use '' for all, comma-separated list via flag, space-separated list via AGENTAPI_ALLOWED_HOSTS env var (default [localhost,127.0.0.1,[::1]])
-o, --allowed-origins strings HTTP allowed origins. Use '
' for all, comma-separated list via flag, space-separated list via AGENTAPI_ALLOWED_ORIGINS env var (default [http://localhost:3284,http://localhost:3000,http://localhost:3001])
-c, --chat-base-path string Base path for assets and routes used in the static files of the chat interface (default "/chat")
-h, --help help for server
-p, --port int Port to run the server on (default 3284)
-P, --print-openapi Print the OpenAPI schema to stdout and exit
-H, --term-height uint16 Height of the emulated terminal (default 1000)
-W, --term-width uint16 Width of the emulated terminal (default 80)
-t, --type string Override the agent type (one of: aider, amp, auggie, claude, codex, cursor, cursor-agent, custom, gemini, goose, custom)

unknown shorthand flag: 'I' in -I=
You are a helpful Coding assistant. Aim to autonomously investigate
hey
`

@Harsh9485
Copy link
Contributor Author

@matifali @DevelopmentCats, I think most of the work is done. check the changes and let me know if I need to change or do anything.

@DevelopmentCats
Copy link
Contributor

@Harsh9485

Are you sure this isn't because you have agent api v0.6.3 pinned in the module which doesn't include the -I flag since it was introduced in https://github.com/coder/agentapi/releases/tag/v0.9.0

@Harsh9485
Copy link
Contributor Author

You’re right, @DevelopmentCats. I updated the agentapi module version, not agentapi itself. Now the initial_prompt is working, and you can review the PR and let me know if you’d like any changes.

@DevelopmentCats
Copy link
Contributor

You’re right, @DevelopmentCats. I updated the agentapi module version, not agentapi itself. Now the initial_prompt is working, and you can review the PR and let me know if you’d like any changes.

I'm glad it was an easy fix 😃

I will test out the module and then give it a final review.

@DevelopmentCats
Copy link
Contributor

@Harsh9485 the last thing you will need to do is update the new module version in the examples to 2.0.0 instead of 1.0.0 which would bring it backwards from 1.1.2

@DevelopmentCats DevelopmentCats merged commit bc39c2e into coder:main Oct 24, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Aider Module: Tasks+AgentAPI Support

3 participants