Repository navigation
Prompt Engineering
jos edited this page Jan 31, 2026
·
1 revision
This project was designed from the start as an experiment in Prompt-Engineered development using Roo and GPT-5.1.
Cross-links: Home · Architecture · Prompt-Engineering · Development-Workflow · API · Doxygen-Integration · Roadmap
The Ping repository does not originate from a hand-written specification or initial code skeleton. Instead, the human role was to:
- Define high-level goals and constraints (e.g., "C++ CLI ping tool with testable architecture and Doxygen docs").
- Encode these goals as structured prompts to Roo.
- Review, execute, and refine GPT-5.1 outputs iteratively.
All major artifacts were generated this way:
- CMake build configuration and layout
- Core C++ modules (session, backends, statistics, exporters)
- Unit and integration tests
- Doxygen configuration files
- Scripts for building, testing, and generating documentation
- This Wiki and other documentation
The typical loop for adding or changing functionality is:
- Clarify the task in natural language (bug, feature, or refactor).
-
Create a focused prompt in Roo that:
- Describes the current behavior
- Provides relevant file paths or code excerpts
- States constraints (e.g., C++17, no external dependencies beyond standard library)
- Run GPT-5.1 to generate or modify code based on this prompt.
- Review and execute: build, run tests, and inspect behavior.
- Refine via follow-up prompts that reference diffs, compiler errors, test failures, or design adjustments.
Design a C++ project named "Ping" that provides a CLI tool and reusable library
for sending ICMP echo requests. Use CMake, modern C++ practices, and a clean
separation between platform-specific ping backends and a generic session layer.
Include unit tests, integration tests, and a Doxygen configuration.
Implement the Windows-specific ping backend that satisfies the existing
platform_ping_backend interface. Use Win32 APIs and keep the implementation
isolated in platform_ping_backend_windows.*. Add tests or mocks where practical.
Generate a GitHub Wiki for the Ping project. Document architecture, the
Prompt-Engineering-based workflow, public APIs, Doxygen integration, and
future roadmap. Use clean Markdown and cross-link all pages.
-
Prompt specificity is critical:
- Clear constraints (platform, standards, testing requirements) greatly improve first-pass quality.
- Referencing file paths and existing symbols helps GPT-5.1 stay consistent.
-
Iterative refinement works best:
- Complex changes are safer when decomposed into smaller prompts.
- Using diffs and compiler/test output in follow-up prompts leads to faster convergence.
-
Architecture matters even with AI:
- A modular, testable design (session vs. backends vs. exporters) makes AI-assisted modifications easier.
- Stable interfaces (e.g., statistics aggregator, exporter contracts) let GPT-5.1 extend behavior without large rewrites.
-
Documentation-first prompts pay off:
- Requesting comments, Doxygen blocks, and usage examples up front reduces later cleanup work.
These practices are reflected across the project and should guide future evolution as described in Development-Workflow and Roadmap.