<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Vorformatiert Zchn";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        mso-fareast-language:DE;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;
        mso-fareast-language:DE;}
span.E-MailFormatvorlage19
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.HTMLVorformatiertZchn
        {mso-style-name:"HTML Vorformatiert Zchn";
        mso-style-priority:99;
        mso-style-link:"HTML Vorformatiert";
        font-family:Consolas;
        mso-fareast-language:EN-US;}
span.E-MailFormatvorlage22
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="DE" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Dear David,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">thank you, that works well!
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">I probably will adapt it to my purpose, but it is a great starting point.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Best regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Wolfgang<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="mso-fareast-language:DE">Von:</span></b><span style="mso-fareast-language:DE"> ACT-R-users [mailto:act-r-users-bounces@act-r.psy.cmu.edu]
<b>Im Auftrag von </b>David Cserjan<br>
<b>Gesendet:</b> Mittwoch, 8. Mai 2024 13:57<br>
<b>An:</b> act-r-users@act-r.psy.cmu.edu<br>
<b>Betreff:</b> Re: [ACT-R-users] Saving a model's state<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p>Dear Wolfgang,<span style="font-size:12.0pt;mso-fareast-language:DE"><o:p></o:p></span></p>
<p>Have you looked into the <i>save-chunks-and-productions.lisp </i>in the extras folder? I never tried it but to me it reads as if it could do what you are looking for!<o:p></o:p></p>
<p>the readme:<o:p></o:p></p>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal">The save-chunks-and-productions.lisp file defines a new command called
<br>
save-chunks-and-productions that can be used to write a model's current <br>
declarative memory, set of productions, general parameters related to <br>
declarative and procedural, the appropriate chunk and proceduction <br>
parameters, and the chunks currently in buffers out to a model file.<br>
<br>
It can be loaded by calling (require-extra "save-model") and that<br>
can be placed into a model file to have it loaded automatically.<br>
Alternatively, one can put the save-chunks-and-productions.lisp file <br>
into the tools directory of the distribution to have it always loaded<br>
or it can be explicitly loaded as needed.<br>
<br>
To use it call the save-chunks-and-productions function passing it<br>
a string which indicates a file to open and write the model information<br>
into.<br>
<br>
More details on exactly what is saved and how to call the new command<br>
can be found in the comments of the save-chunks-and-productions.lisp<br>
file.<o:p></o:p></p>
</blockquote>
<p class="MsoNormal">Best,<br>
David<o:p></o:p></p>
<div>
<p class="MsoNormal">Am 08.05.2024 um 13:44 schrieb Schoppek, Wolfgang:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal">Hi all,<o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">I’m wondering if anybody has written a LISP function that creates ACT-R code from the current state of the model that can be included in an existing model in order to load the last state of the model at a later point
 in time. For my purposes, something like that for new chunks would suffice.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">An example:</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">My model has created the new chunks chunk23, chunk34, chunk45.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">I can get a list of those using sdm.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">I can print their parameters using sdp.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">What I’m looking for is a function that translates this into something like</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">(add-dm </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">  (chunk23 isa …)</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> (chunk34 …</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">  …</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">(sdp chunk23 :reference-count 5 …)</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">(sdp chunk34 …</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">  …</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">… which I can add to my model later to start it from the state it reached at the end of the last run.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">  Wolfgang</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif;mso-fareast-language:DE"><br>
<br>
<o:p></o:p></span></p>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>ACT-R-users mailing list<o:p></o:p></pre>
<pre><a href="mailto:ACT-R-users@act-r.psy.cmu.edu">ACT-R-users@act-r.psy.cmu.edu</a><o:p></o:p></pre>
<pre><a href="https://mailman.srv.cs.cmu.edu/mailman/listinfo/act-r-users">https://mailman.srv.cs.cmu.edu/mailman/listinfo/act-r-users</a><o:p></o:p></pre>
</blockquote>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif;mso-fareast-language:DE"><o:p> </o:p></span></p>
</div>
</div>
</body>
</html>