-
Notifications
You must be signed in to change notification settings - Fork 25
Explanation freeze, grounded and intention.scope #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This really needs some documentation.
A ground expression is an expression with no free variables. For example
Examples: >>> import agentspeak
>>>
>>> X = agentspeak.Var()
>>>
>>> agentspeak.is_ground(X, {})
False
>>> agentspeak.is_ground(X, {X: 3})
True
>>> agentspeak.grounded(X, {})
agentspeak.AslError: term not ground
>>> agentspeak.grounded(X, {X: 3})
3 Freeze substitutes all variables from a given scope into the expression and evaluates it as far as possible. If free variables remain, it returns a structurally identical but independent copy. If you want to make a snapshot of an expression in the current scope, this is more efficient and more convenient than copying the entire scope. On ground expressions, If anything is unclear, please ask for clarification.
Sorry, not sure I understand this question. |
Hey Niklas, thank you for the explanations, that helps a lot already.
I misunderstood what the intention scope is and thought that there was a way of adding context to a belief. I didn't know that the scope refers to variables and their bindings. |
Hi Niklas,
could you briefly explain what freezing a literal means and what part the intention scope plays?
Does intention scope refer to the context which describes where a goal was raised?
Is it possible to transfer the intention.scope to python so that when adding achievement goals or beliefs the scope can be heeded?
What does 'ground' refer to?
I looked the mentioned things up in the source code and googled everything but I don't get it so far. 😬
Thank you! :)
Cornelius
The text was updated successfully, but these errors were encountered: