-
Notifications
You must be signed in to change notification settings - Fork 1
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
Seed data for example notebooks? #5
Comments
I have almost the same issue. Did you solved it? I used the methods of the cookbook notebooks to post the given example on my local server but now I'm a bit confused about sending a .sysml file directly since it is only shown for a JSON format data input ( e.g. "Element_Create_Update_Delete.ipynb"). Inside Jupyter notebook it is all handled by the magic %publish command which post a request with a sysml file and transforms it automatically in the right file format but only to the official test servers (http://sysml2.intercax.com:9000/docs/) I hope someone can help me. |
Hello Folks These notebooks are showing direct interaction with the Systems Modeling API and Services REST API on a pilot implementation server. This can done using any programming language but Jupyter notebooks with Python are used for their ease. However, this should not be mixed/confused with the SysML v2 textual notation and use of the SysML v2 language kernel in Jupyter where SysML v2 models can be authored and published to the repository via the same REST API as above. A simple workflow to get started:
I hope this helps. Best Regards |
Hello Manas, Thanks for you answer. I already did this workflow and it works very well but I wanted to test that on a local server, which can all be done with the given python code inside the API Cookbook as well. In this case: I can't really send a sysml file directly to the local server (which is done by %publish to the test servers) but I can create, edit a project via json format (as shown in the recipes). Therefore I have to "rewrite" my sysml file so that I have the same json-ld format for sending it on my local server right? The confusion is that the %publish command in Jupyter Notebook transforms a .sysml file to a JSON format. I was trying to get achieve kinda the same with more automation and custom GUI. Since working with the API directly I cant just send a .sysml file but have to map/translate the sysml file to JSON. Is that the intended way? How can I achieve the same when I just want to upload a .sysml file? Another point is that for the JSON format (send request) there are no good documentation about how I can send/create a project with more content (in one example: project_data = { |
I have the API running locally but the data initialized empty so none of the provided notebooks have the example outputs. Is there a way to seed the database with the example data or another .sysml file? If not, are there examples showing how to correctly create and insert sysml data via the REST API?
The text was updated successfully, but these errors were encountered: