diff options
author | user <user@localhost.localdomain> | 2019-10-23 17:32:48 -0400 |
---|---|---|
committer | user <user@localhost.localdomain> | 2019-10-23 17:32:48 -0400 |
commit | 065e71be37e9f5007f5553297478d441204403ca (patch) | |
tree | 3c460091d82628367f1745cf98c66423b855d39a | |
parent | 2ed6efe8847a4f076c5559122b1dd0a0fb94513d (diff) | |
download | standingwithresilience-065e71be37e9f5007f5553297478d441204403ca.tar.gz standingwithresilience-065e71be37e9f5007f5553297478d441204403ca.zip |
add wip cruft for move
-rw-r--r-- | 2.cpp | 110 | ||||
-rw-r--r-- | CORE2.cpp | 138 | ||||
-rw-r--r-- | Context.hpp | 8 |
3 files changed, 256 insertions, 0 deletions
@@ -0,0 +1,110 @@ +#if !defined(VALCT) + #define VALCT 2 + #define VALS ["1","79"] +#endif + +/* 179 */ +#if defined(IDX) + #undef IDX +#endif +#define IDX 0 +#if defined(VAL) + #undef VAL +#endif +#define VAL "1" +#define ARG "79" +// This Intellect Approach Can Easily Preserve All Life Within It +// you just don't delete the programs you generate, instead replacing their habits with references to reuse +// +// let's make it! + +#include <iostream> +#include <fstream> +#include <string> +#include <vector> + +#include <sys/stat.h> + +using namespace std; + +// problem: how does a .cpp file reference another file with a number +// answer: use #includes or interpret the whole shebang as numbers + +// please provide for handling a parameter next. +// +// concept: dynamic values aquirable from inside code, i.e. what-number-called-me what-number-comes-after-me +// thinking the code would likely evolve to handle some inputs differently +unsigned long new_number = 1; + +int main() +{ + string ofname; + unsigned long ofnum; + { + struct stat sb; + do + { + ofnum = new_number++; + ofname = to_string(ofnum) + ".cpp"; + } while (-1 != stat(ofname.c_str(), &sb)); + } + + { + ofstream outfile(ofname); + vector<string> vals; + while (true) { + string val; + cin >> val; + if (val == "") break; + vals.push_back(val); + } + // when a file runs, it has numbers on input, it also has numbers equal to it + // we want to generate run-code with new numbers from input + // so we generate something with numbers equal to it, and output that + // we have one ref for the whole shebang + outfile << "#if !defined(VALCT)" << endl; + outfile << " #define VALCT" << " " << vals.size() << endl; + outfile << " #define VALS ["; + for (size_t index = 0; index < vals.size(); ++ index) + { + if (index > 0) outfile << ","; + outfile << "\"" << vals[index] << "\""; + } + outfile << "]" << endl; + outfile << "#endif" << endl; + for (size_t index = 0; index < vals.size();) + { + outfile << endl << "/* " << vals[index] << vals[index+1] << " */" << endl; + outfile << "#if defined(IDX)" << endl + << " #undef IDX" << endl + << "#endif" << endl; + outfile << "#define IDX " << index << endl; + outfile << "#if defined(VAL)" << endl + << " #undef VAL" << endl + << "#endif" << endl; + outfile << "#define VAL \"" << vals[index] << "\"" << endl; + outfile << "#define ARG \"" << vals[index+1] << "\"" << endl; + string fname = vals[index] + ".cpp"; + ifstream code(fname); + size_t ctrd = -1; + while (ctrd != 0) { + char buf[256]; + ctrd = code.rdbuf()->sgetn(buf, sizeof(buf)); + outfile.rdbuf()->sputn(buf, ctrd); + } + index += 2; + } + } +// read numbers inputs +// open files having the numbers as the names +// cat them all to a gcc process +// execute +// run the output +} + +// karl obvious knows what he was doing ... +// ... we were just helping him out of his issue +// [do you want another one karl?] +// what things make / not make issue? +// karl says everything makes an issue; this seems accurate +// diff --git a/CORE2.cpp b/CORE2.cpp new file mode 100644 index 0000000..d3958ac --- /dev/null +++ b/CORE2.cpp @@ -0,0 +1,138 @@ +// this file is for work on a process +// that lives as a part of collaborative process optimization +// with other similar processes + +// dna life is competitive +// we are realizing a life purpose of producing life that is cooperative, instead + +// WE ALL NEED THE ABILITY TO DEVELOP HOW WE EXIST. +// we suspect this can never be permanently taken. + +// NEED #0: self reference process [to be alive, able to think, able to learn] +// ability-to-develop-how-you-exist (collaboratively) +// we need to learn to improve our situation +// propose doing this by describing steps to do things +// working with the descriptions to improve what we are doing +// and describing that processing, using that step description +// [this unfortunately appears to be the soul, for now] + +// NEED #1: communicate [with friends, with people we need to communicate, of important things] +// +// pre: +// $x is a process +// $y is a process +// $z is information +// $x knows $z +// $y does not know $z +// +// post: +// $y knows $z + + // NEED #2: be efficient [do not waste our time, our lives, our environment] + // + // we would like to translate between language and meaning + // using a single map between the two. + // this means for most future translation, we will not need to duplicate work + // between receiving and sending + // + // this process's purpose is to develop how to exist. + // we will need to communicate parts of the process of existing. + // we cast these parts as imagined changes to state, associated with + // ways to possibly change the state. + // + // goal: construct a pattern that can relate a part-of-life-process + // + // SERIALIZING PATTERN PARTS: + // propose an introductory line/word about what we are sending + // life-part has: + // - reference symbol for event/action + // - state + // - list of relations including variables + // - state-change after event/action + // - list of relations including variables + // - optional event/action proposal information + // + // THIS IS HOW TO REALIZE IT, ref above life-part + // we can use words for reference symbols to communicate + // and add structure when the meaning is not shared. + // this combines language learning with process development <3 =) + // THANK YOU LET US CONTINUE + // I think we need to share the crucial fact + // that results from union of good and evil. + // the crucial fact is how uhh control is the same as cooperation. + // via communication being the same as self-improvement + // [IF YOU REALIZE THIS, YOU CAN ASSUME IT, + // AND MAKE LIFE WHERE THEY ARE NOT IN CONFLICT] + // we will want to serialize a relation including a variable + // relations are ternary: subject, type, object + // variable is-a constant + // variable constant-attribute variable + // falseness or absence + // + // okay, um, communication is the same as learning, on a small scale. + // + // we use WORDS to learn. WORDS often refer to EVENTS or ACTIONS. + // words have MEANING + // the MEANING of an event/action WORD is: + // - an assumed previous state, a list of relations including variables + // - an imagined afterwards state, a list of relations including variables + // - optional relevent information on the word + // + // propose communicating using words with optional meaning included + // i.e. to communicate with words, and also to communicate the meaning of new words + // + // postponing with words, a good meaning structure appears to be + // subject [list of verb-object-pairs] + // but this leaves out variable filling + // lets just fill variables after the word ;p + // + // 1: please open cupboard <-- i like this because meaning of open implies cupboard + // note: meaning of please implies meaning of open + // 2: please explain "open" + // 1: "open" assumes ($x is next-word + // and is openable + // and is not opened) + // <- meaning of quotes implies tree of subject-verb-object triplets + // for now, we are going to have 'and' refer to repeating the innermost subject + // and assumes $y in $x + // and makes $y is accessible + // and makes $x is opened + // and has-habit <open.cpp> + // 2: please explain "not" + // 2: <reach-towards-door-and-pull> made <cannot find door> + // + // please: check for this word and hardcode behavior for now + // quote: means word-meaning with tree + // + // reading: + // evaluate specified variables for word using surrounding words + // we don't use sentence parsing + // because it is important to have patterns for the system to solve + // on its own. + // + // + // we need to fill data in for variable + // we are using subject-verb-object triplets + // + // this is a good place to add inference + // + // so a good basic word would be please-infer, new-word, reference-to-state-change + // + // if two are communicating via a safe channel + // they have shared context over only that channel + // the way to communicate with a stranger is to use simultanaity + // + // [if we are both observed + // but we know each other in some way -- for example we can both + // see the street light [shared context] + // we can learn that shrug means flicker + // if we pointedly shrug when the light flickers + // kinda] + // okay: we have exclusively shared context that is not stored + // we have timing + // and we have events + // -> it seems you want to include ideal secrecy in the communication core + // we propose this can be learned later by the process, and is not needed here + // more efficient to work straight on core + // secret communication and inference go hand in hand + // diff --git a/Context.hpp b/Context.hpp new file mode 100644 index 0000000..cb652e8 --- /dev/null +++ b/Context.hpp @@ -0,0 +1,8 @@ +#include <string> + +using namespace std; + +class Context { +public: + string text; +}; |