rosett-ai 1.5.12 → 1.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cb0358498de4f1123fd29a3ae3e728712340a70772a5469a31d25048a4525aca
4
- data.tar.gz: bbc11a0a29c5d4b8b14fe3c34e9d28ae93c1046b1b6fc6f1758f09e4c8d21684
3
+ metadata.gz: 8968373d949471c707db0f0bddbe526797d8e47fdaf80b53a17d65e7fb5cb198
4
+ data.tar.gz: efdd68439a73eb12e2f6b503e999c2d0a40c9a6d9c73693da59cbacd9c3dab0c
5
5
  SHA512:
6
- metadata.gz: bbfc6704a022cbc1077b0c394282abb6ed055aea1de6810d7bfc56b915c2749831ba9484b2325aae150601bd8cf8c01db2b84e17856e2a71c928184b06121436
7
- data.tar.gz: 8a143b9cb92ee1e6dad0622cd0da6275e806589e6ec10fb171111af98a0e21882a24e4f952652e0b7b40aa079c69cda8b57f07cd7bfc2b1d5949030b1bb5021b
6
+ metadata.gz: 82e690044b7a4b4a54d3bf5f562c1b27711cb462b973d5d3d0078c3c0c8e84ca20dec5f027949d4cd0c233c26d4d321fe42cb20cfe9bb8ab7bdb068613c7787f
7
+ data.tar.gz: 4680e074d51a261d6ad4a98ce477d990b2ddf4187b30f90883c3d26cb86b1c7cfe6502b0ea7c5a07434f692111dc296e9a5eebb4ecb6477913bb5e6516b111d8
data/CHANGELOG.md CHANGED
@@ -6,6 +6,35 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [1.6.1] - 2026-07-23
10
+
11
+ ### Security
12
+
13
+ - **CVE-2026-41316**: pin `erb` to `>= 6.0.6`; update Gemfile.lock to erb 6.0.6 —
14
+ resolves the gem-level vector of the ERB deserialization bypass advisory.
15
+
16
+ ## [1.6.0] - 2026-07-19
17
+
18
+ ### Added
19
+
20
+ - **Behaviour-rule schema v1.4.0** — three new optional, backward-compatible fields on rule items,
21
+ laying the foundation for mechanical context-load reduction:
22
+ - `enforced: boolean` — marks rules whose behaviour is deterministically enforced by a live
23
+ PreToolUse/other hook; the C2 lean-context emitter will omit these from loaded bundles.
24
+ - `applies_to: [enum]` — one or more of `worker-impl`, `worker-research`, `orchestrator`,
25
+ `interactive`, `all`; the C3 role-scoped emitter uses this to produce per-role bundles.
26
+ Absence is treated as `["all"]`.
27
+ - `evidence: string` — the "Why / On \<date\> / incident" provenance narrative, separated from
28
+ the imperative rule body; the C2 lean emitter strips this field to reduce context size.
29
+ All three fields are optional; existing behaviour YAML files validate unchanged.
30
+
31
+ ### Security
32
+
33
+ - **`mcp` gem upgraded 0.9.2 → 0.25.0** — fixes five CVEs in the MCP ruby-sdk:
34
+ GHSA-52jp-gj8w-j6xh, GHSA-5p9g-j988-pcwv, GHSA-7683-3w9x-ch42, GHSA-h669-8m4g-r2hc,
35
+ GHSA-rjr6-rcgv-9m7m (memory exhaustion, session poisoning, DNS-rebinding; all fixed in 0.23.0).
36
+ Dependency constraint widened from `~> 0.9.2` to `>= 0.23.0`.
37
+
9
38
  ## [1.5.12] - 2026-07-15
10
39
 
11
40
  ### Fixed
@@ -4,8 +4,8 @@
4
4
  "title": "NeatNerds Behaviour Configuration",
5
5
  "description": "Schema for validating behaviour configuration files used by the NeatNerds Code Companion (rosett-ai). Behaviour files define operational rules for Claude Code workflows.",
6
6
  "$comment": {
7
- "date": "2026-04-17",
8
- "version": "1.3.0",
7
+ "date": "2026-07-19",
8
+ "version": "1.4.0",
9
9
  "source": "rosett-ai",
10
10
  "compatible_claude_code_versions": [
11
11
  ">=0.1.0"
@@ -148,6 +148,30 @@
148
148
  "type"
149
149
  ],
150
150
  "additionalProperties": false
151
+ },
152
+ "enforced": {
153
+ "type": "boolean",
154
+ "description": "True when a live PreToolUse or other hook deterministically enforces this rule. Hook-enforced rules can be omitted from lean context bundles (C2 emitter). Absence is treated as false."
155
+ },
156
+ "applies_to": {
157
+ "type": "array",
158
+ "description": "Session roles this rule applies to. Used by the role-scoped bundle emitter (C3) to include only relevant rules per role. Absence is treated as [\"all\"].",
159
+ "items": {
160
+ "type": "string",
161
+ "enum": [
162
+ "worker-impl",
163
+ "worker-research",
164
+ "orchestrator",
165
+ "interactive",
166
+ "all"
167
+ ]
168
+ },
169
+ "minItems": 1,
170
+ "uniqueItems": true
171
+ },
172
+ "evidence": {
173
+ "type": "string",
174
+ "description": "Provenance narrative — the 'Why / On <date> / incident' context separated from the imperative rule body. Stripped from lean bundles (C2 emitter). Absence is treated as no separate evidence (provenance stays inline in description)."
151
175
  }
152
176
  }
153
177
  }
@@ -72,6 +72,24 @@ module RosettAi
72
72
  # @return [Array] Parameter types passed as keyword arguments.
73
73
  KEYWORD_PARAM_TYPES = [:keyreq, :key].freeze
74
74
 
75
+ # Lightweight adapter so plain resource-entry hashes satisfy the mcp >= 0.23.0
76
+ # server.resources= API, which requires objects responding to #uri and #to_h.
77
+ class ResourceListEntry
78
+ def initialize(attrs)
79
+ @attrs = attrs
80
+ end
81
+
82
+ def uri
83
+ @attrs[:uri]
84
+ end
85
+
86
+ def to_h
87
+ { uri: @attrs[:uri], name: @attrs[:name], description: @attrs[:description],
88
+ mimeType: @attrs[:mimeType] }.compact
89
+ end
90
+ end
91
+ private_constant :ResourceListEntry
92
+
75
93
  module_function
76
94
 
77
95
  # @param server [MCP::Server]
@@ -89,8 +107,9 @@ module RosettAi
89
107
  # @param server [MCP::Server]
90
108
  def register_resources(server)
91
109
  resources = RESOURCE_CLASSES.map(&:new)
92
- server.resources_list_handler { resources.flat_map(&:list) }
93
- server.resources_read_handler do |uri:|
110
+ server.resources = resources.flat_map(&:list).map { |e| ResourceListEntry.new(e) }
111
+ server.resources_read_handler do |params|
112
+ uri = params.is_a?(Hash) ? (params[:uri] || params['uri']) : params.to_s
94
113
  resource_name = uri.split('/').last
95
114
  resource_class = find_resource_for_uri(resources, uri)
96
115
  result = resource_class&.read(resource_name)
@@ -5,5 +5,5 @@
5
5
 
6
6
  module RosettAi
7
7
  # @return [String] Current version of the rosett-ai gem.
8
- VERSION = '1.5.12'
8
+ VERSION = '1.6.1'
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rosett-ai
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.12
4
+ version: 1.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hugo Antonio Sepulveda Manriquez
@@ -237,16 +237,16 @@ dependencies:
237
237
  name: mcp
238
238
  requirement: !ruby/object:Gem::Requirement
239
239
  requirements:
240
- - - "~>"
240
+ - - ">="
241
241
  - !ruby/object:Gem::Version
242
- version: 0.9.2
242
+ version: 0.23.0
243
243
  type: :runtime
244
244
  prerelease: false
245
245
  version_requirements: !ruby/object:Gem::Requirement
246
246
  requirements:
247
- - - "~>"
247
+ - - ">="
248
248
  - !ruby/object:Gem::Version
249
- version: 0.9.2
249
+ version: 0.23.0
250
250
  description: Configuration management tool for AI-assisted development workflows.
251
251
  Author rules once, compile to Claude Code, Cursor, AGENTS.md, and more.
252
252
  email: