Batch 24 (20261102-C-bos-seed-24) screened all 3078 Bos seed queries. Only 23 themes were in scope (pure user-space reliability, at most one task per theme); the rest were single operations or explanations, installs and networking, system administration, ROS2, board-only or GUI requests. Two finished drafts were withdrawn as too close to existing tasks. Seeds supply direction only: all sources, contracts and tests are new, and no task shares more than 14 characters with its seed text. Each task passed the local gate and the trace6 Docker gate (5 runs per sample class). Claude rebuilt the catalog from the calibration receipts: 23/23 USABLE. 16 of 23 are C/C++. Only the task directories are taken; the batch worktree's lowered disk floor in rollout/core.py stays out of main. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
47 lines
1.2 KiB
C++
47 lines
1.2 KiB
C++
#pragma once
|
|
|
|
#include <cstdint>
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
namespace carrier {
|
|
|
|
enum class CommandKind {
|
|
enable,
|
|
disable,
|
|
up,
|
|
down,
|
|
complete,
|
|
fail,
|
|
advance,
|
|
query,
|
|
history,
|
|
reset_log,
|
|
invalid
|
|
};
|
|
|
|
struct Command {
|
|
CommandKind kind = CommandKind::invalid;
|
|
unsigned port = 0;
|
|
std::uint64_t value = 0;
|
|
};
|
|
|
|
class CommandReader {
|
|
public:
|
|
Command parse(const std::string& line) const;
|
|
private:
|
|
std::vector<std::string> words(const std::string& line) const;
|
|
bool number(const std::string& word, std::uint64_t& result) const;
|
|
bool port_number(const std::string& word, unsigned& result) const;
|
|
bool one_port(const std::vector<std::string>& tokens,
|
|
CommandKind kind, Command& result) const;
|
|
bool port_and_value(const std::vector<std::string>& tokens,
|
|
CommandKind kind, Command& result) const;
|
|
bool one_value(const std::vector<std::string>& tokens,
|
|
CommandKind kind, Command& result) const;
|
|
bool no_argument(const std::vector<std::string>& tokens,
|
|
CommandKind kind, Command& result) const;
|
|
};
|
|
|
|
} // namespace carrier
|