agentsclimarketplace

Run1 scala testing and type safety

Skill cxcscmu/SkillLearnBench/skills/b3-teacher-feedback-claude-haiku-4-5/python-scala-translation/run1_scala-testing-and-type-safety

[COLM'26] SkillLearnBench is the first benchmark for evaluating continual learning methods that automatically generate agent skills.

Install
npx -y skills add cxcscmu/SkillLearnBench --skill run1_scala-testing-and-type-safety

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

What its author says it does

Copied from the file, not written here

Scala's type system features, testing patterns, and integration with test specifications for ensuring correctness of translated code.

SKILL.md

1.7 KB, 341 tokens by cl100k_base, as published. Nobody here has run it

Scala Type Safety

Explicit Type Annotations

  • Always annotate public method return types
  • Use specific types, not Any
def tokenize(input: String): List[Token] = { ... }

Generic Types

class Container[T](value: T) {
  def get: T = value
}

Type Bounds

  • Use upper bounds for constraints: T <: BaseType
  • Use lower bounds when appropriate: T >: BaseType

Reading Test Specifications

Understanding Expected Signatures

  • Review /root/TokenizerSpec.scala for method signatures
  • Note parameter types and return types exactly
  • Identify any builder patterns or fluent API requirements
  • Check for implicit parameters or type classes

Common Test Patterns

  • Test construction: how objects are instantiated
  • Test core functionality: main methods work as expected
  • Test edge cases: empty input, special characters, boundary conditions
  • Test composition: methods work together correctly

Compilation and Type Checking

Scala 2.13 Compatibility

  • Avoid Scala 3-only features
  • Use standard library features available in 2.13
  • Be aware of deprecations and use stable APIs

Compiler Errors

  • Type mismatches are caught at compile time
  • Use the Scala REPL or scalac to verify code
  • Pay attention to implicit resolution errors

Property-Based Testing Concepts

  • Even though you won't write tests, understand that test specs often verify:
    • Invariants (properties that always hold)
    • Round-trip properties (encode/decode consistency)
    • Composition properties (f(g(x)) behaves correctly)

Gives 0 of the 12 instructions most test skills give in 341 tokens

Counted across 964 of the 1,571 authors here whose files we hold, read 2026-08-07

  • close the browser when donein 55 of 964, across 12 files
  • wait for network idle statein 51 of 964, across 6 files
  • launch chromium in headless modein 49 of 964, across 6 files
  • use descriptive selectors for elementsin 49 of 964, across 6 files
  • run provided scripts with help flag firstin 49 of 964, across 6 files
  • add appropriate explicit waitsin 48 of 964, across 5 files
  • use bundled scripts as black boxesin 46 of 964, across 3 files
  • do not read script source codein 46 of 964, across 3 files
  • use sync playwright for scriptsin 46 of 964, across 3 files
  • inspect dom before executing actionsin 46 of 964, across 3 files
  • run the full test suitein 37 of 964
  • write the failing test firstin 29 of 964, across 23 files

Said here and by no other author read

  • annotate public method return types explicitly
  • use specific types, not Any
  • use upper bounds for generic type constraints
  • match parameter and return types exactly
  • identify builder patterns or fluent API requirements
  • check for implicit parameters or type classes

Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.