Lua Features in Foldit

Started by Tlaloc

Tlaloc Lv 1

I have been employed by the foldit team to add features that are missing to allow more powerful scripts (aka recipes or macros). After a week of getting up to speed, I am now starting to slowly get some of those long-missing features in. They only have me for a limited time, so here is your big chance to get that feature into foldit scripting you have always wanted.

First, let me put a limit on the requests that you make…I will be adding functions to lua scripting, or in some minor cases changing how they operate (for example, relaxing the 20 unit band length). The features I will be working on need to already be implemented in the foldit user interface, as I am mainly only adding lua wrappers to existing functionality (with a few exceptions).

I have looked through the forum and feedback posts. As far as I can tell, this is a pretty comprehensive list, and what I will be working from:

http://foldit.wikia.com/wiki/Lua_Functions_That_Should_Be_Implemented
http://foldit.wikia.com/wiki/Lua_Standard_Libraries
http://fold.it/portal/node/987880

The best way to make a request is to modify the wiki page at the URL above. Posting here also works, and acts as a vote for a feature. I will be working with Seth and Zoran to triage the requests, work out a spec, and get as many of them in as I can. Some requests are much easier to implement than others, of course. The more specific on how you want that function to operate, the more likely it is that we can get it in. Try to explain exactly what you want, what the arguments are, what it should return, and what operations it should perform.

The things that Zoran is particularly interested in are features that allow more exploration. How can you create a script that will make a radically different shaped protein? What is keeping you from doing that?

infjamc Lv 1

A command-line option would be nice, as this would allow the user to enter Lua functions directly and change parameters without having to edit the scripts.

Tony Origami Lv 1

This is the most exciting news since I started with foldit. Your wish list is highly comprehensive but it is unlikely that you will be able to implement more than a small fraction in a month. For me the following would make the greatest difference.

  1. Script output to file
  2. External script editor enabled
  3. Save protein from script
  4. Load saved protein from script
  5. Script input from file

spvincent Lv 1

My wish list.

1) The ability to write to a file (the name could even be hard-coded if necessary)
2) Finer control over wiggling: the ability to stop at or near a particular score would be particularly useful.
3) Add math library
4) The functionality of the tweak tool made accessible via the API (except maybe the register shift tool: don't care about that)
5) get_xyz. Return the position of a particular residue (the alpha carbon I suppose) in whatever coordinate system is convenient.
6) get_sidechain_snap. Return the current snap position. Low priority for me but may be low-hanging fruit.

And an improved development environment would not come amiss.

Rav3n_pl Lv 1

On my "dream target" inputbox is on first place:

string intputbox('Comment string','default value')

Why return string? We not always need numerical value and lua translating it into int or float anyway if need :)

Why inputbox? Most of my scripts is very customizable. I always try to post in on best (imo) options but sometimes it need tweaking anyway (depends on puzzle, mood, time of day… ;]). That way we can kill zillions of customized scripts in book.
But saving customized script would be nice too (overwrite default value/s in script and save on different name).

My second best is cookbook:

  • sorting (by name, number of uses, author…)
  • folders (at least depth of 2, ie walkers/mine/script )
  • rename
  • good working delete and adding in selection interface :)
  • tag showing that script is downloaded, changed, shared to me/group/all
  • unshare any script I made (to clean site a bit form old script, I have some old scripts deleted form book and want to remove them from site/shared to me/shared to group. So I download recipe, unshare, delete for good)
  • normal access to scripts code - not "all.macro" odd encoded file but plain text .lua files.

Rest I (we?) want/need posted there: http://fold.it/portal/node/987880#comment-11192

cjmarsh Lv 1

A few things I'd like to have in the toolbox:
– import/using options for CLR-compliant dynamically linked libraries (.dlls)
– higher precision parameters for iterations of methods such as Wiggle and Shake
– exposure of the inner workings of fold.it's proprietary methods (provided the IP rights are secure)
– GUI creation with input status getters and simple button implementation
– methods for xml or database conversion to image type and 2D rendering to screen coordinates

Some of the items on my wishlist would no doubt be easier to implement than others, but any number of them would certainly be helpful. Thanks for putting the time in to improve the overall scripting process, I appreciate it.

Mike Cassidy Lv 1

Being able to copy&paste on a MAC; I am a bad typist and do not want to keep typing the same commands in.

Tony Origami Lv 1

amongst the information functions required is one giving the origin and insertion of constraints - perhaps a table of constraints

cjmarsh Lv 1

I second this request, if the constraints are known, then 'wiggle', 'shake', 'tweak' and the rest can be combined with 'restore recent best' to obtain the minimum constraints with the maximum score.