~/talk

Automated Type Contracts Generation for Ruby

Talkat RubyKaigi 2017 · 2017-09-18..09-20· [ruby, ai-assisted-development]
links:none on file
slides:none on file

Runtime traces collected with tracepoint plus occasional YARV disassembly turn method calls into input→output tuples which are compressed into contracts like (String, T) -> T. Rules become NFAs that the system determinizes and minimizes (NFA→DFA minimization) and can merge across runs and projects; proto tooling includes arc_scanner gem, a server for merging, and an IDE plugin. Tests run much slower under tracing (tens×), so collection is intended as a one‑time or CI job.

AI-written summary · about

  1. 0:00Introduction and motivation
  2. 3:35Why Ruby needs types
  3. 7:46Limitations of testing and static analysis
  4. 10:59Collecting type data with TracePoint
  5. 17:29Handling corner cases in data collection
  6. 18:12Transforming raw data into type contracts
  7. 23:13Improving contract generation with bit masks
  8. 24:50Merging automatons for consistency
  9. 27:04Demo: Generating type annotations
  10. 29:30Building a global type database
  11. 31:16Project architecture and tools
  12. 33:49Future possibilities and impact
  13. 34:34Q&A session
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.