Randomly extract non-overlapping sets
Generate content for a word game. Input is data about relations (A-to-B strength). Output is distant relationships.
For example:
GOOD: apple, airplane, dog, house
BAD: banana, cherry, peach, strawberry.
You do NOT need to speak very much English. This is purely data.
I have two source files. A list of ranked relationships between words, and a separate list of words which may be in the first file. This is real English word data, similar to a thesaurus. https://www.powerthesaurus.org/
Task is to randomly output sets of lines from the 2nd file, which are NON-overlapping concepts.
An ideal algorithm would create a multidimensional mesh, and then randomly extract distant nodes. I don't know how to do that. i.e. output sets of words which are all distant in vector space. See: https://dzone.com/articles/introduction-to-word-vectors
A non-ideal algorithm would randomly pull lines from file 2, measure similarity to other output lines, if dissimilar, keep and remove from file 2. If a line in file 2 is similar to too many test lines, remove it and return to file 2. i.e. a "bag of coins", and you keep randomly testing/replacing coins so they are all different.
No word pair should be more than 0.3 similar; and the total similarity of all words between sets should be <0.5.
Preferred programming language is: ruby, perl, python.
Two input files:
A) relations.txt
#aaa [syn]: aab | aac; [syn-score]: 100.0 | 8.0;
#aab [syn]: aaa | aac; [syn-score]: 75.0 | 5.0;
#bbb [syn]: bba | bbc; [syn-score]: 50.0 | 4.3;
#bba [syn]: bbb | bbc; [syn-score]: 150.0 | 1.2;
#ccc [syn]: ccd | ccz; [syn-score]: 150.0 | 0.4;
... etc.
B) lists.txt
#aaa = aab | aac
#bbb = bbd | bba
#bba = bbd | bbx
#ccc = cca | ccz
#cca = ccd | cce
#ddd = dda | ddb
... etc.
The real file A is 300+ MB, with 855k lines.
The real file B is ~15k lines.
I will want to be able to set N, number of sets; and Y number of packs. N will typically be around 25 sets; and Y will likely be 1000 packs.
Output, with N=2:
#aaa = aab | aac
#cca = ccd | cce
#bbb = bbd | bba
#ddd = dda | ddb
#bba = bbd | bbx
#ccc = cca | ccz
Output, with N=3:
#aaa = aab | aac
#ccc = cca | ccz
#bba = bbd | bbx
#bbb = bbd | bba
#ddd = dda | ddb
#cca = ccd | cce
Aktualne zlecenia dla freelancerów w kategorii Programowanie stron internetowych
Należy stworzyć formularz Gravity Forms według szablonu czatuTrzeba stworzyć formularz Gravity Forms według szablonu czatu. Znajomość lub przynajmniej zrozumienie angielskiego jest konieczne!!! Dostarczę stronę, na której znajduje się coś w rodzaju czatu online, gdzie trzeba wybierać opcje, a w zależności od tych opcji otwierają się nowe… Programowanie stron internetowych ∙ 12 godzin 30 minut temu ∙ 41 ofert |
Tworzenie lub korekta strony na opencartWitam wszystkich! Wstępna sytuacja do zrozumienia: Zamówiłem rozwój strony internetowej u Templatemonsters. Z góry uzgodniłem specyfikację i kupiłem od nich szablon. W rezultacie nie dotrzymano terminów i w ogóle napisali, że nie mogą zrobić tak, jak uzgodniono. Hosting kupiłem… Programowanie stron internetowych, Sklepy internetowe i e-commerce ∙ 20 godzin 2 minuty temu ∙ 30 ofert |
Rozwój aplikacji mobilnej AI z bajkami dla dzieciPoszukuję doświadczonego programisty lub zespołu do stworzenia aplikacji mobilnej z sztuczną inteligencją, która będzie generować krótkie, miłe i dostosowane do wieku bajki dla dzieci prosty, piękny i bezpieczny produkt, w którym rodzic w kilka minut może stworzyć osobistą… AI i uczenie maszynowe, Programowanie stron internetowych ∙ 21 godzin 4 minuty temu ∙ 38 ofert |
Tłumacz dla WordPress.Trzeba przetłumaczyć stronę WordPress z WooCommerce na 30 języków. Wtyczka do wygodnego automatycznego tłumaczenia. Żeby nie klikać na każdą stronę w celu tłumaczenia i każdy produkt. Żeby można było robić wyjątki dla określonych fraz. Można było poprawiać tłumaczenie.… Programowanie stron internetowych, Kompleksowe prace nad stroną internetową ∙ 21 godzin 40 minut temu ∙ 24 oferty |
Poprawki dla strony na OpencartStrona veselkatm.com.ua na OpenCart Wersja 3.0.3.8 1) Udoskonalić koszyk Stworzyć metody dostawy: - Ukrposzta - Nova Poshta Zainstalować i skonfigurować moduły, aby wszystko działało poprawnie Stworzyć metody płatności: - Płatność przy odbiorze - Na konto - Na kartę 2)… Content Management Systems, Programowanie stron internetowych ∙ 1 dzień temu ∙ 56 ofert |