How istin/dmtools works
Project Type and Purpose
• DMTools is a Java-based, full-stack CLI/library tool (monolithic JAR) offering “Delivery Management” features.
• It’s invoked via a job trigger (UrlEncodedJobTrigger) and integrates with external systems (Jira, GitHub, GitLab, Bitbucket, Rally, Confluence, Figma, OpenAI, Firebase, AppCenter) to collect, analyze, enrich, and report data.
• It also includes a simple Chrome Extension for user interaction (popup and settings).
File Structure
• Top-level build: Gradle wrapper, build.gradle, settings.gradle, GitHub workflows, gradle-publish.
• chrome_extension/: simple UI layer.
• src/main/java/com/github/istin/dmtools/: core packages by domain:
• job – JobRunner, UrlEncodedJobTrigger
• di – dependency-injection modules for AI, Atlassian, context, agents, search, etc.
• ai – orchestrator, agents, AI client adapters (OpenAI, CurlAI).
• atlassian, github, gitlab, broadcom.rally, bitbucket – REST client adapters/models.
• common – shared models, utils, networking.
• src/test & src/integrationTest: comprehensive unit & integration tests.
README
• Describes: CLI invocation, environment-variable-driven configuration for each external service.
• Mentions: API description for job params, JAR build, configuration for Jira, Rally, Bitbucket, GitHub, GitLab, Confluence, OpenAI, CurlAI, Figma, Firebase, AppCenter.
a. Main Components
• CLI Launcher: UrlEncodedJobTrigger → JobRunner
• DI Container: wires selected modules & agents
• Job service layer: AbstractJob & concrete Job implementations
• Context Orchestrator: aggregates inputs (files, tickets, code)
• AI Layer: AIProvider, AI clients (OpenAI/CurlAI), agents
• Adapters for External Systems: Jira, GitHub, GitLab, Bitbucket, Rally, Confluence, Figma, Firebase, AppCenter
• Reporting & Output: Freemarker template engine → HTML, PDF, Excel, Markdown
• Optional UI: Chrome Extension (popup/settings)
b. Relationships & Data Flow
1. User invokes CLI with base64 JobParams → CLI Launcher
2. JobRunner parses params & selects Job implementation
3. DI Container injects required clients & orchestrators
4. Job uses adapters to fetch data from external systems
5. ContextOrchestrator + ChunkPreparation prepare inputs for AI
6. AI Layer (through AIProvider) calls external AI API
7. Agents process AI responses, merge content, generate artifacts
8. Reporting modules apply Freemarker templates → deliver output files or update Confluence/Jira
9. Chrome Extension can display results, allow settings modification
c. Architectural Patterns & Principles
• Modular package organization by domain
• Adapter pattern for each external REST API
• Dependency Injection (via custom DI modules)
• Template Method for Jobs
• Strategy/Agent pattern for AI tasks
• Template Engine (Freemarker) for outputs
• Separation of concerns: data retrieval, processing, AI, templating
d. Key Technologies & Frameworks
• Java 11+; Gradle (shadowJar plugin)
• Freemarker for templating
• HTTP clients (RestClient, AtlassianRestClient)
• Base64-encoded JobParam API
• Chrome Extension (HTML/JS manifest v2/3)
Essential Elements
• Labels: component name, package/module
• Green: Internal services (Jobs, Agents)
• Blue: External integrations (Jira, GitHub, …)
• Yellow: AI subsystem
• Gray: Output (Freemarker, templates)
• Orange: CLI & UI (Chrome Extension)
• Notes on triggers (base64 JobParams) and DI assembly.
Final Advice
• Major domain modules you see under src/main/java/com/github/istin/dmtools.
• Platform as a single monolith broken into logical layers, not microservices.
• Don’t over-fragment—group by layer/domain.
• Be detailed but clear: the goal is to reflect how data moves from CLI → adapters → AI → agents → templates → outputs.
• Review the README’s list of supported systems to ensure each adapter is shown.
• Iterate with the team: they may want to show sample Jobs (e.g., “DevProductivityReport” job) as examples.