Skip to content

docs: Add verification examples to skill documentation #20

@marcfargas

Description

@marcfargas

Problem

Our skill documentation shows how to perform operations but often lacks verification steps. This gap was exposed when investigating follower notifications (#19) - we had examples for message_subscribe and message_post but no verification that followers were actually added or notifications created.

Example of the gap:

// We documented this:
await client.call('res.partner', 'message_subscribe', [[partnerId]], {
  partner_ids: [followerPartnerId]
});
// But not this verification:
const followers = await client.searchRead('mail.followers', [
  ['res_model', '=', 'res.partner'],
  ['res_id', '=', partnerId],
  ['partner_id', '=', followerPartnerId]
], { fields: ['id'] });
assert(followers.length > 0, 'Follower should be added');

Proposal

Update skill documentation to include verification patterns after operations:

  1. CRUD operations - Verify with read/search after create/write/unlink
  2. Method calls - Verify side effects (followers added, notifications created, etc.)
  3. State changes - Verify the expected state after actions

Benefits

  • Agents can self-verify their work
  • Catches silent failures (like kwargs being ignored)
  • Reinforces testing culture
  • Documents expected behavior more completely

Files to Update

  • mail/chatter.md - Add verification after message posting
  • mail/discuss.md - Add verification for channel operations
  • mail/activities.md - Add verification for activity creation
  • base/crud.md - Add verification patterns section
  • Other module skills as appropriate

Related

Discovered while investigating notification behavior - the root cause was issue #19 (execute vs execute_kw), but better verification examples would have caught this sooner.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions