feat: Add an agent skill for working with setup chain#136
Conversation
794d0a3 to
3d6b11f
Compare
|
|
||
| ## Custom Signatures (Advanced) | ||
|
|
||
| Only manually push `this.tasks` when action signature deviates from `(opts, label)`: |
There was a problem hiding this comment.
if (opts, label) is the true default signature, perhaps the signature in number 1 should be (opts, _label) or (opts, label)?
There was a problem hiding this comment.
for number 1 - the label isn't passed to the actual action function, Thats only for defining the custom hook on the chain instance
There was a problem hiding this comment.
async myAction(arg1, arg2) {
}vs
class MyChain extends Chain {
myAction(arg1, ar2, label) {
this.tasks.push(['myAction', label, arg1, arg2])
}
}| - **Inside Action Options**: | ||
| You can pass function calls as values in action options; they will be resolved by the action's `this.lookup()` call. | ||
| ```javascript | ||
| chain.myAction({ slug: '!slugify(#title)' }) |
There was a problem hiding this comment.
maybe say here that the results are in chain.state.myAction and say what the value is.
In fact, we don't really talk about how to use chain.state, but I use it often when I don't want to assign the .execute's return val to a variable. Not sure where that should go, but I think somewhere.
There was a problem hiding this comment.
hmm. I have never used the internal state property directly. I tend to treat that as inside baseball / don't mess with it
There was a problem hiding this comment.
you mean you always do chain.lookup('myAction')?
There was a problem hiding this comment.
yeah, use lookup, or the return value from execute(), mostly the latter
cbed2b2 to
b43deae
Compare
|
The build fail is an old npm token problem. looking at it |
This adds a skill that confirms to the agentskills.io. It should work with most any agent provider. It can be discovered by the skills.sh cli This includes instructions on adding actions and functions, as well as some guidence on general usage. Resolves: #135
update the test matrix to include node 20, 22, 24
b43deae to
f4aa522
Compare
update eslint and bas config to latest version and corrects outstanding linting errors
f4aa522 to
96cb56b
Compare
This adds a skill that confirms to the agentskills.io spec. It should work with most any agent provider. It can be discovered by the skills.sh cli
This includes instructions on adding actions and functions, as well as some guidence on general usage.
Resolves: #135