Skip to content

Commit da74897

Browse files
committed
Merge branch 'release/1.3.1' into main
2 parents 03d22e5 + b76fcd9 commit da74897

File tree

8 files changed

+112
-19
lines changed

8 files changed

+112
-19
lines changed

.agents/skills/conch-generator/SKILL.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,31 @@ Use this skill when you need to:
110110
- Use the `useDhti` route from the monorepo (esm-dhti-utils) to call the DHTI service and get GenAI outputs. You need to update the DHTI service route (dhtiRoute) in the config-schema.ts file. If the user has not provided it above, ask for it using a prompt.
111111
If the user has only provided the DHTI service name, construct the full route as follows: http://localhost:8001/langserve/dhti_elixir_<service-name>/cds-services/dhti-service. Otherwise use the default value as 'http://localhost:8001/langserve/dhti_elixir_schat/cds-services/dhti-service'
112112
113+
### Directory Structure
114+
115+
```
116+
workspace/
117+
└── dhti-elixir/
118+
└── packages/
119+
└── <name>/ # Your generated elixir package
120+
├── notes/todo.md # Your detailed TODO list and plan
121+
├── src/dhti_elixir_<name>/ # Main code for the elixir
122+
│ ├── chain.py # Main chain implementation
123+
│ ├── bootstrap.py # Bootstrap/configuration file
124+
│ ├── README.md # Documentation for your elixir
125+
│ └── (other files, e.g., __init__.py, utils.py)
126+
├── pyproject.toml # Add new dependencies here
127+
└── tests/
128+
└── test_chain.py # Example test file for chain.py
129+
└── openmrs-esm-dhti/
130+
└── packages/
131+
└── esm-dhti-<name>/ # Your generated elixir package
132+
├── notes/todo.md # Your detailed TODO list and plan
133+
├── src/ # Main code for the conch with multiple subdirectories.
134+
├── package.json # Update dependencies and metadata here
135+
└── README.md # Documentation for your conch
136+
```
137+
113138
## Implementation Steps
114139
115140
- Start implementing the feature based on your plans. Follow best practices for React and OpenMRS frontend-module development. When you are in doubt refer to the implementation guide here: https://r.jina.ai/https://o3-docs.openmrs.org/docs/frontend-modules/overview. Test your code frequently to ensure it works as expected.

.agents/skills/elixir-generator/SKILL.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,31 @@ di["dhti_elixir_<<name>>_cds_hook_discovery"] = { # <- <<name>>
8888
}
8989
```
9090
91+
### Directory Structure
92+
93+
```
94+
workspace/
95+
└── dhti-elixir/
96+
└── packages/
97+
└── <name>/ # Your generated elixir package
98+
├── notes/todo.md # Your detailed TODO list and plan
99+
├── src/dhti_elixir_<name>/ # Main code for the elixir
100+
│ ├── chain.py # Main chain implementation
101+
│ ├── bootstrap.py # Bootstrap/configuration file
102+
│ ├── README.md # Documentation for your elixir
103+
│ └── (other files, e.g., __init__.py, utils.py)
104+
├── pyproject.toml # Add new dependencies here
105+
└── tests/
106+
└── test_chain.py # Example test file for chain.py
107+
└── openmrs-esm-dhti/
108+
└── packages/
109+
└── esm-dhti-<name>/ # Your generated elixir package
110+
├── notes/todo.md # Your detailed TODO list and plan
111+
├── src/ # Main code for the conch with multiple subdirectories.
112+
├── package.json # Update dependencies and metadata here
113+
└── README.md # Documentation for your conch
114+
```
115+
91116
## High level functional requirements for chain.py and bootstrap.py implementation
92117
- **Align with the reference pattern:**
93118
- Mirror the structure, abstractions, and flow used in the reference chain.py and bootstrap.py.

.agents/skills/start-dhti/SKILL.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,31 @@ The user conversation may provide context on the work you have done in the past.
2828
- Check that Node.js and Docker are installed
2929
- Verify Docker is running: `docker ps`
3030

31+
2. **Directory Structure**
32+
33+
```
34+
workspace/
35+
└── dhti-elixir/
36+
└── packages/
37+
└── <name>/ # Your generated elixir package
38+
├── notes/todo.md # Your detailed TODO list and plan
39+
├── src/dhti_elixir_<name>/ # Main code for the elixir
40+
│ ├── chain.py # Main chain implementation
41+
│ ├── bootstrap.py # Bootstrap/configuration file
42+
│ ├── README.md # Documentation for your elixir
43+
│ └── (other files, e.g., __init__.py, utils.py)
44+
├── pyproject.toml # Add new dependencies here
45+
└── tests/
46+
└── test_chain.py # Example test file for chain.py
47+
└── openmrs-esm-dhti/
48+
└── packages/
49+
└── esm-dhti-<name>/ # Your generated elixir package
50+
├── notes/todo.md # Your detailed TODO list and plan
51+
├── src/ # Main code for the conch with multiple subdirectories.
52+
├── package.json # Update dependencies and metadata here
53+
└── README.md # Documentation for your conch
54+
```
55+
3156
### Phase 2: Set Up DHTI Infrastructure
3257

3358
5. **Create Docker Compose Configuration:**

CHANGELOG.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,11 @@
22

33
## [Unreleased](https://github.com/dermatologist/dhti/tree/HEAD)
44

5-
[Full Changelog](https://github.com/dermatologist/dhti/compare/1.2.0...HEAD)
6-
7-
**Closed issues:**
8-
9-
- Build a new command that uses the COPILOT-SDK to interact with DHTI and display results. [\#119](https://github.com/dermatologist/dhti/issues/119)
5+
[Full Changelog](https://github.com/dermatologist/dhti/compare/1.3.0...HEAD)
106

117
**Merged pull requests:**
128

9+
- Feature/fix start skill 1 [\#121](https://github.com/dermatologist/dhti/pull/121) ([dermatologist](https://github.com/dermatologist))
1310
- Add GitHub Copilot SDK integration with skill-based streaming AI assistance and stateful conversations [\#120](https://github.com/dermatologist/dhti/pull/120) ([Copilot](https://github.com/apps/copilot-swe-agent))
1411
- Feature/agent skills 2 [\#118](https://github.com/dermatologist/dhti/pull/118) ([dermatologist](https://github.com/dermatologist))
1512
- Feature/agent skills 1 [\#117](https://github.com/dermatologist/dhti/pull/117) ([dermatologist](https://github.com/dermatologist))
@@ -36,6 +33,14 @@
3633
- Feature/bump fix 1 [\#87](https://github.com/dermatologist/dhti/pull/87) ([dermatologist](https://github.com/dermatologist))
3734
- Feature/copy bootstrap [\#86](https://github.com/dermatologist/dhti/pull/86) ([dermatologist](https://github.com/dermatologist))
3835

36+
## [1.3.0](https://github.com/dermatologist/dhti/tree/1.3.0) (2026-02-14)
37+
38+
[Full Changelog](https://github.com/dermatologist/dhti/compare/1.2.0...1.3.0)
39+
40+
**Closed issues:**
41+
42+
- Build a new command that uses the COPILOT-SDK to interact with DHTI and display results. [\#119](https://github.com/dermatologist/dhti/issues/119)
43+
3944
## [1.2.0](https://github.com/dermatologist/dhti/tree/1.2.0) (2026-01-24)
4045

4146
[Full Changelog](https://github.com/dermatologist/dhti/compare/1.1.0...1.2.0)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Generative AI features are built as [LangServe Apps](https://python.langchain.co
2828
🚀 Checkout **[Vidhi Recipes](/vidhi/README.md)** for chatbot, RAG, imaging (DICOM) and MCPX for dockerized calculators
2929

3030
#### How (non‑technical / clinical)
31-
DHTI includes ready‑to‑use [skills](/.github/skills/) that can prompt agentic platforms (e.g., [AntiGravity](https://antigravity.google/), VSCode, or Claude) to generate the GenAI backends and UI components (elixirs and conches) you need. Test these components with synthetic data in OpenMRS or the CDS‑Hooks sandbox, then hand them off to production teams. Because DHTI follows open standards, that handoff (the “valley of death”) becomes smoother and more predictable. Try the [prompts](/.github/skills/start-dhti/examples/e2e-sample.md) in your preferred agentic platform after cloning this repo.
31+
DHTI includes ready‑to‑use [skills](/.agents/skills/) that can prompt agentic platforms (e.g., [AntiGravity](https://antigravity.google/), VSCode, or Claude) to generate the GenAI backends and UI components (elixirs and conches) you need. Test these components with synthetic data in OpenMRS or the CDS‑Hooks sandbox, then hand them off to production teams. Because DHTI follows open standards, that handoff (the “valley of death”) becomes smoother and more predictable. Try the [prompts](/.agents/skills/start-dhti/examples/e2e-sample.md) in your preferred agentic platform after cloning this repo.
3232

3333
Other skills from the open agent skills ecosystem may be useful too! For example, use `npx skills find clinical trial` to find clinical trial related skills. From the results, you can use `npx skills add <skill-name>` to use the skill in your agentic platform. (e.g.`npx skills add anthropics/healthcare@clinical-trial-protocol-skill`)
3434

notes/COPILOT.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,6 @@
44
DHTI now integrates with GitHub Copilot SDK, enabling AI-assisted workflows directly from the command line with **stateful conversations**:
55

66
```bash
7-
# Interactive AI assistance with auto-skill detection
8-
npx dhti-cli copilot --prompt "Start the DHTI stack with langserve and ollama"
9-
10-
# Continue the conversation - history is automatically maintained
11-
npx dhti-cli copilot --prompt "Now add redis to the configuration"
127

138
# Use specific skills for specialized tasks
149
npx dhti-cli copilot --prompt "Create a patient risk assessment elixir" --skill elixir-generator
@@ -22,6 +17,9 @@ npx dhti-cli copilot --clear-history --prompt "Start a new conversation"
2217
# Or just clear history without starting a new conversation
2318
npx dhti-cli copilot --clear-history
2419

20+
# Interactive AI assistance with auto-skill detection
21+
npx dhti-cli copilot --prompt "Start the DHTI stack with langserve and ollama"
22+
2523
# Available skills: start-dhti, elixir-generator, conch-generator, or auto (default)
2624
```
2725

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "dhti-cli",
33
"description": "DHTI CLI",
4-
"version": "1.3.0",
4+
"version": "1.3.1",
55
"author": "Bell Eapen",
66
"bin": {
77
"dhti-cli": "bin/run.js"

src/commands/copilot.ts

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ import {fileURLToPath} from 'node:url'
1111
* and display results with streaming support.
1212
*/
1313
export default class Copilot extends Command {
14-
static override description =
15-
'Interact with DHTI using GitHub Copilot SDK with streaming responses'
14+
static override description = 'Interact with DHTI using GitHub Copilot SDK with streaming responses'
1615

1716
static override examples = [
1817
'<%= config.bin %> <%= command.id %> --prompt "Start the DHTI stack with langserve"',
@@ -77,8 +76,19 @@ export default class Copilot extends Command {
7776
return 'conch-generator'
7877
}
7978

80-
// Default to start-dhti for general setup/orchestration
81-
return 'start-dhti'
79+
// Use start-dhti if prompt includes 'start', 'show', or 'run'
80+
if (lowerPrompt.includes('start') || lowerPrompt.includes('show') || lowerPrompt.includes('run')) {
81+
return 'start-dhti'
82+
}
83+
84+
// If none of the skills match, exit asking for a skill name and show available skills
85+
const availableSkills = ['start-dhti', 'elixir-generator', 'conch-generator']
86+
this.error(
87+
`Could not detect the appropriate skill from the prompt.\n` +
88+
`Please specify a skill name using --skill.\n` +
89+
`Available skills: ${availableSkills.join(', ')}`,
90+
)
91+
return ''
8292
}
8393

8494
/**
@@ -245,7 +255,8 @@ export default class Copilot extends Command {
245255
}
246256

247257
// Build system message with skill instructions
248-
let systemMessageContent = 'You are a helpful assistant that can use specific skills to generate components of the DHTI stack based on user prompts.'
258+
let systemMessageContent =
259+
'You are a helpful assistant that can use specific skills to generate components of the DHTI stack based on user prompts.'
249260

250261
// Add skill-specific instructions
251262
if (skillContent) {
@@ -322,13 +333,17 @@ export default class Copilot extends Command {
322333
}
323334

324335
this.saveConversationHistory(conversationHistory)
325-
this.log(chalk.dim(`💾 Conversation saved (${conversationHistory.length} messages). Use --clear-history to reset.`))
336+
this.log(
337+
chalk.dim(`💾 Conversation saved (${conversationHistory.length} messages). Use --clear-history to reset.`),
338+
)
326339
} catch (error) {
327340
const errorMessage = error instanceof Error ? error.message : String(error)
328341
this.error(
329342
chalk.red(`Failed to interact with Copilot SDK: ${errorMessage}\n\n`) +
330343
chalk.yellow('Troubleshooting:\n') +
331-
chalk.yellow('1. Ensure GitHub Copilot CLI is installed: https://docs.github.com/en/copilot/using-github-copilot/using-github-copilot-in-the-command-line\n') +
344+
chalk.yellow(
345+
'1. Ensure GitHub Copilot CLI is installed: https://docs.github.com/en/copilot/using-github-copilot/using-github-copilot-in-the-command-line\n',
346+
) +
332347
chalk.yellow('2. Authenticate with: copilot auth login\n') +
333348
chalk.yellow('3. Verify CLI is working: copilot --version\n'),
334349
)

0 commit comments

Comments
 (0)