Hello,
I'm a grad student. I will have to use this Model Inference Tool for my research in specification mining and model based testing. I am wondering if I can get any documentation regarding how to use this tool. Thank you.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have now written a brief manual that describes how to install and use the tool. After you clone the repository from GitHut, the manual can be found in resources/introduction/index.html
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Kiril,
Thank you very much for that manual.
I installed it. It is working on your sample trace file. Some of your trace file contains state machine (in text format) and a part of the statechum visualizes it. Now I have a couple questions.
1. I have a java project. I would like to generate FSM using statechum. I guess it generates traces from the java source code or the execution. And from the trace it generates state machine. I couldn't figure it out how do I generate trace. Do I need to write code to generate it based on statechum framework or is there any sample class or GUI or command to do that? It would be better for quick learners if you kindly show how to do this.
2. Does statechum generate state machine for C and Assembly programes as well?
Thank you.
Last edit: Syed Samsul Arefin 2015-11-13
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
We did some work on generation of FSM from the Java source code based on symbolic execution using Java Pathfinder,
N. Walkinshaw, K. Bogdanov, M. Holcombe
Identifying State Transitions and their Functions in Source Code
1st IEEE Testing Academia & Industrial Conference (TAIC PART'06),
Windsor, UK, August, 2006
You can download it by googling the title. I'm happy to discuss this work but we did not do much more than that on generation of models from the source code.
Most of the work on Statechum is not based on generation of traces from source code, you are expected to instrument your system to log the run-time data of interest and then use Statechum to learn from it. There is no direct support for logging in Statechum since only you know what is interesting to log and what is not. For instance, for the i2c experiment I logged all interrupts and the commands that I have issed to the chip, in order to find out why some tasks were apparently taking too long. I did not need to log the specific data that was transmitted since it was not relevant; if looking at an FSM it appeared that data was important, I would have added it to the log.
You do not need Statechum to generate traces, it is enough to generate text files that you can then supply to QSMTool. The i2c experiment includes traces that I generated from embedded C code (by having the chip report events via a serial port) and the .java class loads them into Statechum and runs the learner. The traces and the loader are in the Statechum git repository.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Kiril,
I got it now. Thank you very much. I have some trace files. I have run an experiment on that trace. I have provided only the method names from the trace and I got the state machine. This is very interesting. I would like to know more about the parameters that statechum requires(i.e., the format of the trace file). Does it consider the runtime values of the method parameters? If so then what is the specific format should I consider? Would you please recommend me anything about how can I get the most out of the statechum.
I have read the below book chapter you have written.
Chapter-3: Adapting Grammar Inference Techniques to Mine State Machines
Mining Software Specifications: Methodologies and Applications
I think you have implemented those algorithms in statechum.
Thanks again.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The current implementation does not use argument values. There is an experimental version in development that aims to take them into account but this is work in progress and is not yet usable.
The most obvious way to use values is to turn them into strings and concatenate with labels. In this way, each combination of argument values will produce a unique label, potentially leading to a huge alphabet. A better way is to abstract the values, such as by recording whether it is greater than zero or not (very much like what Daikon tool does). You would then use such abstractions as part of labels, producing a rather more manageable collection of labels. How to abstract is very domain-specific and there is no easy answer.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
I'm a grad student. I will have to use this Model Inference Tool for my research in specification mining and model based testing. I am wondering if I can get any documentation regarding how to use this tool. Thank you.
Syed,
The main repository has now moved to Github,
https://github.com/kirilluk/statechum
I have now written a brief manual that describes how to install and use the tool. After you clone the repository from GitHut, the manual can be found in resources/introduction/index.html
Kiril,
Thank you very much for that manual.
I installed it. It is working on your sample trace file. Some of your trace file contains state machine (in text format) and a part of the statechum visualizes it. Now I have a couple questions.
1. I have a java project. I would like to generate FSM using statechum. I guess it generates traces from the java source code or the execution. And from the trace it generates state machine. I couldn't figure it out how do I generate trace. Do I need to write code to generate it based on statechum framework or is there any sample class or GUI or command to do that? It would be better for quick learners if you kindly show how to do this.
2. Does statechum generate state machine for C and Assembly programes as well?
Thank you.
Last edit: Syed Samsul Arefin 2015-11-13
Syed,
We did some work on generation of FSM from the Java source code based on symbolic execution using Java Pathfinder,
N. Walkinshaw, K. Bogdanov, M. Holcombe
Identifying State Transitions and their Functions in Source Code
1st IEEE Testing Academia & Industrial Conference (TAIC PART'06),
Windsor, UK, August, 2006
You can download it by googling the title. I'm happy to discuss this work but we did not do much more than that on generation of models from the source code.
Most of the work on Statechum is not based on generation of traces from source code, you are expected to instrument your system to log the run-time data of interest and then use Statechum to learn from it. There is no direct support for logging in Statechum since only you know what is interesting to log and what is not. For instance, for the i2c experiment I logged all interrupts and the commands that I have issed to the chip, in order to find out why some tasks were apparently taking too long. I did not need to log the specific data that was transmitted since it was not relevant; if looking at an FSM it appeared that data was important, I would have added it to the log.
You do not need Statechum to generate traces, it is enough to generate text files that you can then supply to QSMTool. The i2c experiment includes traces that I generated from embedded C code (by having the chip report events via a serial port) and the .java class loads them into Statechum and runs the learner. The traces and the loader are in the Statechum git repository.
Kiril,
I got it now. Thank you very much. I have some trace files. I have run an experiment on that trace. I have provided only the method names from the trace and I got the state machine. This is very interesting. I would like to know more about the parameters that statechum requires(i.e., the format of the trace file). Does it consider the runtime values of the method parameters? If so then what is the specific format should I consider? Would you please recommend me anything about how can I get the most out of the statechum.
I have read the below book chapter you have written.
Chapter-3: Adapting Grammar Inference Techniques to Mine State Machines
Mining Software Specifications: Methodologies and Applications
I think you have implemented those algorithms in statechum.
Thanks again.
Syed,
The current implementation does not use argument values. There is an experimental version in development that aims to take them into account but this is work in progress and is not yet usable.
The most obvious way to use values is to turn them into strings and concatenate with labels. In this way, each combination of argument values will produce a unique label, potentially leading to a huge alphabet. A better way is to abstract the values, such as by recording whether it is greater than zero or not (very much like what Daikon tool does). You would then use such abstractions as part of labels, producing a rather more manageable collection of labels. How to abstract is very domain-specific and there is no easy answer.