soargroup / visualsoar Goto Github PK
View Code? Open in Web Editor NEWVisualSoar is a development environment written in Java to aid in the creation of agents for use in Soar
VisualSoar is a development environment written in Java to aid in the creation of agents for use in Soar
It's common to combine the Soar code of multiple agents into one. In this case the datamap of any of the original agents will not suffice alone, and the entire agent can only be validated after the multiple datamaps are combined. It would be nice to automate this.
The offending line in a rule is: (<s> ^raw-feature-queue.feature-info.lti-for-feature { @ 9876 <whatever> })
Basically, I don’t think it understands the “@” test. When I remove the @, the “check productions against datamap” button has no error. (The rule doesn’t make sense then in the context of the agent, but I was just checking if otherwise the visualsoar parser could handle the syntax.) (I haven’t exhaustively tested, but I imagine this extends to @+, @-, and !@ tests as well.)
The rule works in the agent as intended when I run the agent with the @ test.
The error message:
Unable to check productions due to parse error
all\elaborations\LTI-conditioned-elaborations(16): parser.ParseException: Encountered " "{" "{ "" at line 16, column 57. Was expecting one of:
")" ...
"-" ...
"^" ...
"." ...
"<<" ...
"[" ...
"<>" ...
"<=>" ...
"<" ...
"<=" ...
">=" ...
">" ...
"=" ...
...
<INTEGER_CONST> ...
<SYMBOLIC_CONST> ...
<FLOATING_POINT_CONST> ...
When Visual Soar is compiled with Linux and run on Windows we were seeing aberrent behavior: a) failure to syntax highlight or b) unable to load/edit any rules file in the project.
I've already fixed this issue but want to create a separate Issue to track it.
On John's machine and on mine, it doesn't seem to do anything.
From @PLindes: if you just open a VisualSoar project, the project files are often changed even when the user has not edited the datamap or any code yet.
This is confusing and worrying for users; who do you know when files are changed in a significant way? How do you know when you should commit? Do the changes cause change in functionality?
I bet there's some part of the code that just reads and immediately writes out the files again, with non-deterministic ordering due to using a HashMap or similar under the hood.
When a new message appears, it may not immediately be apparent to the user. I'm thinking it should flash briefly with a white color. It might do something else though.
Once Visual Soar's status bar message is set, it keeps its value until set to something else. Instead, the message should be reset when the user performs some new interaction (i.e., hits a key, selects a new menu option).
It would be nice to be able to select the font and font-size used for displaying the code in the editor.
The above file is a .soar file with the extension changed to .txt so github will accept it.
When I try to check against the datamap, this file produces lots of errors, as shown in this file:
It appears that all the errors originate from the places where there is a variable for an attribute, as in lines 38 and 73 of the .soar file. A Soar agent seems to handle this just fine, but Visual Soar does not seem to understand it.
Some users have commented that changes to datamap files are difficult to merge in Git, making collaboration on datamap files (and by extension many Soar codebases) very difficult.
Investigate what can be done to improve the datamap format to make it very easy to merge parallel changes.
Static code analysis for Soar is very rare, and datamap checking in VisualSoar is probably the most valuable that exists. As VisualSoar really doesn't offer a great programming experience (compared to VSCode, Sublime, etc.), it would be nice to have the datamap functionality in a library so that we could use it elsewhere.
Imagine integrating it into the Soar LSP, then getting feedback while you write in VSCode. Or imagine building on the library to verify Soar WM itself so you get a warning when a non-datamap-compliant WME structure appears in working memory. Imagine having this functionality built directly into the Soar debugger.
if I recall correctly, RL was changed so that now the agent expects ^reward-link.reward.value <float-val>
(so, the default datamap should be changed too)
It’s almost impossible to copy text from the editor or the main window and get it into the clipboard so it can be pasted into some other document.
For example if myfile.soar is older than myfile.soar~, then Visual Soar should notice that upon loading the project and give the user the option to use the auto-backup file instead.
Does not seem to work.
build.xml must be changed like so in order for the jar to work in the final release:
<property name="manifest.classpath" value="java/sml.jar" />
Note that this does not work for development, where sml.jar
is located in lib/
. For the debugger build, we have a separate manifest for development and release. We should probably do a similar thing here.
Note also that the manifest.classpath
is given twice in the build. I just remove one and fix the other.
I created a new project from scratch in VisualSoar 4.6.16. Then I added a bunch of code to the initialize operator to create a deep data structure. (The initialize-test-1.soar file is attached with its extension changed to .txt so GitHub will accept it.) Then I clicked on the Generate Datamap Entries for this file a number of times. Each time it added more depth to the datamap. When it finally wouldn't add any more, I saved the project and closed VisualSoar, with tabs open for both the top state datamap and the initialize operator.
When I tried to open the project again, I got this error and could never recover the project:
When working on a system with multiple screens, popup windows are not shown on the same screen as the main window. For instances, when creating the data map from existing operators, a popup with confirmation pops up, but on a whole different screen. This popup may not be obvious to the user, so it appears that VS has frozen since you can't do anything with it until the popup is closed.
I have only tried on my machine, but syntax coloring isn't working. It works when I roll back which visualsoar version I'm using by swapping out the jar file.
When Visual Soar launches, it attempts to open whatever project you had open last time. However, if that project was last opened as Read-Only, Visual Soar re-opens it as an editable project. This can be an annoyance to a user who is trying to keep a particular project intact.
To address this, Visual Soar should remember the read-only status that was used the last time a project was opened.
I opened a project (read only).
I then clicked "Datamap" and "generate the datamap from the current operator hierarchy".
Then, I opened the datamap and clicked "validation" and "validate datamap".
Then, I closed the project.
There were changes in datamap files within the project.
This could be my user error, but I'm unaware how to get visualsoar to validate a rule containing a line like the following:
(<real-obj> ^<const-attr> <match-value>)
I don't even really know what I'm supposed to do in this case.
Some users commented that it appears that VS ignores ._all files when running project datamap validation. Confirm whether this is true and document it in the manual.
I opened a VisualSoar project in read-only mode. After I had closed VisualSoar GitHub reported the following changes in the comments.dm file:
I'm discarding these changes that should not have been made, and I assume that will not affect the project in other ways.
The image also shows a change in line endings from 'LF' to 'CRLF'. I'm working on Windows, where 'CRLF' is the standard. Does VisualSoar change these? It would be nice if it used the convention for whatever OS it is running on.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.