Lawfare Group → Knowledge Institute → Lawfare Academy
Limited checks for the original foundation-program inquiry
Copy this complete code into a UTF-8 file and run with Python 3. Standard library only, synthetic records, no network or learner records. Formal/count/budget checks do not decide interpretation, knowledge, moral justification, actual authority or observed proficiency.
"""Foundation program: limited synthetic logic, counting and feasible-set checks."""
from itertools import product
from fractions import Fraction as F
import json
checks=[]
imp=lambda d,c:not d or c
counter=[dict(adopted=d,consulted=c) for d,c in product([False,True],repeat=2) if imp(d,c) and c and not d]
assert counter==[dict(adopted=False,consulted=True)];checks.append(dict(case='consultation countermodel',result=counter))
checks.append(dict(case='independent adoption fact',result='An added true adoption premise supports adoption; it does not validate the original converse inference.'))
attempts=set(range(24));contacts=set(range(19,31));assert len(attempts)==24 and len(contacts)==12 and len(attempts&contacts)==5 and len(attempts|contacts)==31
assert F(16,24)==F(2,3)
unions=[24+12-overlap for overlap in range(13)];assert min(unions)==24 and max(unions)==36
checks.append(dict(case='independent set reconstruction',completionRate=str(F(16,24)),knownOverlapUnion=len(attempts|contacts),unknownOverlapRange=[min(unions),max(unions)]))
# Tokens and informational pattern are distinct fields, not a test of a metaphysical theory.
tokens=[dict(token='left-record',content='same-pattern'),dict(token='right-record',content='same-pattern')]
assert tokens[0]['content']==tokens[1]['content'] and tokens[0]['token']!=tokens[1]['token']
checks.append(dict(case='content and token distinction',result='Matching represented content is compatible with distinct token identifiers; no legal ownership or personal identity follows.'))
plans={'A':dict(parts=[10,2],refusedImage=False),'B-original':dict(parts=[6,6],refusedImage=True),'B-no-image-expanded':dict(parts=[6,6,1],refusedImage=False),'B-prime':dict(parts=[5,6,1],refusedImage=False),'wait':dict(parts=[0],refusedImage=False)}
def feasible(plan,budget=12,assume_refusal_condition=True):return sum(plan['parts'])<=budget and not(assume_refusal_condition and plan['refusedImage'])
assert {name for name,plan in plans.items() if feasible(plan)}=={'A','B-prime','wait'}
assert sum(plans['B-no-image-expanded']['parts'])==13
changed={**plans,'B-with-costless-removal':dict(parts=[6,6],refusedImage=False)}
assert feasible(changed['B-with-costless-removal'])
checks.append(dict(case='complete feasible set',originalFeasible=['A','B-prime','wait'],changedAdds='B with actual costless image removal',boundary='A supplied hypothetical refusal condition and budget restrict this set; they do not establish actual legal permission, effects or a unique moral ranking.'))
print(json.dumps(dict(passed=True,checks=checks,boundary='Limited formal and stipulated-count checks only. Interpretation, knowledge, moral/political justification, actual permission, independent review and observed learner proficiency are not established by code.',learnerRecordsAccessed=False),indent=2))
Complete inquiry, explanations, optional applications and rubric