api.go 233 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567
  1. // THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
  2. // Package machinelearning provides a client for Amazon Machine Learning.
  3. package machinelearning
  4. import (
  5. "fmt"
  6. "time"
  7. "github.com/aws/aws-sdk-go/aws/awsutil"
  8. "github.com/aws/aws-sdk-go/aws/request"
  9. )
  10. const opAddTags = "AddTags"
  11. // AddTagsRequest generates a "aws/request.Request" representing the
  12. // client's request for the AddTags operation. The "output" return
  13. // value can be used to capture response data after the request's "Send" method
  14. // is called.
  15. //
  16. // See AddTags for usage and error information.
  17. //
  18. // Creating a request object using this method should be used when you want to inject
  19. // custom logic into the request's lifecycle using a custom handler, or if you want to
  20. // access properties on the request object before or after sending the request. If
  21. // you just want the service response, call the AddTags method directly
  22. // instead.
  23. //
  24. // Note: You must call the "Send" method on the returned request object in order
  25. // to execute the request.
  26. //
  27. // // Example sending a request using the AddTagsRequest method.
  28. // req, resp := client.AddTagsRequest(params)
  29. //
  30. // err := req.Send()
  31. // if err == nil { // resp is now filled
  32. // fmt.Println(resp)
  33. // }
  34. //
  35. func (c *MachineLearning) AddTagsRequest(input *AddTagsInput) (req *request.Request, output *AddTagsOutput) {
  36. op := &request.Operation{
  37. Name: opAddTags,
  38. HTTPMethod: "POST",
  39. HTTPPath: "/",
  40. }
  41. if input == nil {
  42. input = &AddTagsInput{}
  43. }
  44. req = c.newRequest(op, input, output)
  45. output = &AddTagsOutput{}
  46. req.Data = output
  47. return
  48. }
  49. // AddTags API operation for Amazon Machine Learning.
  50. //
  51. // Adds one or more tags to an object, up to a limit of 10. Each tag consists
  52. // of a key and an optional value. If you add a tag using a key that is already
  53. // associated with the ML object, AddTags updates the tag's value.
  54. //
  55. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  56. // with awserr.Error's Code and Message methods to get detailed information about
  57. // the error.
  58. //
  59. // See the AWS API reference guide for Amazon Machine Learning's
  60. // API operation AddTags for usage and error information.
  61. //
  62. // Returned Error Codes:
  63. // * InvalidInputException
  64. // An error on the client occurred. Typically, the cause is an invalid input
  65. // value.
  66. //
  67. // * InvalidTagException
  68. //
  69. // * TagLimitExceededException
  70. //
  71. // * ResourceNotFoundException
  72. // A specified resource cannot be located.
  73. //
  74. // * InternalServerException
  75. // An error on the server occurred when trying to process a request.
  76. //
  77. func (c *MachineLearning) AddTags(input *AddTagsInput) (*AddTagsOutput, error) {
  78. req, out := c.AddTagsRequest(input)
  79. err := req.Send()
  80. return out, err
  81. }
  82. const opCreateBatchPrediction = "CreateBatchPrediction"
  83. // CreateBatchPredictionRequest generates a "aws/request.Request" representing the
  84. // client's request for the CreateBatchPrediction operation. The "output" return
  85. // value can be used to capture response data after the request's "Send" method
  86. // is called.
  87. //
  88. // See CreateBatchPrediction for usage and error information.
  89. //
  90. // Creating a request object using this method should be used when you want to inject
  91. // custom logic into the request's lifecycle using a custom handler, or if you want to
  92. // access properties on the request object before or after sending the request. If
  93. // you just want the service response, call the CreateBatchPrediction method directly
  94. // instead.
  95. //
  96. // Note: You must call the "Send" method on the returned request object in order
  97. // to execute the request.
  98. //
  99. // // Example sending a request using the CreateBatchPredictionRequest method.
  100. // req, resp := client.CreateBatchPredictionRequest(params)
  101. //
  102. // err := req.Send()
  103. // if err == nil { // resp is now filled
  104. // fmt.Println(resp)
  105. // }
  106. //
  107. func (c *MachineLearning) CreateBatchPredictionRequest(input *CreateBatchPredictionInput) (req *request.Request, output *CreateBatchPredictionOutput) {
  108. op := &request.Operation{
  109. Name: opCreateBatchPrediction,
  110. HTTPMethod: "POST",
  111. HTTPPath: "/",
  112. }
  113. if input == nil {
  114. input = &CreateBatchPredictionInput{}
  115. }
  116. req = c.newRequest(op, input, output)
  117. output = &CreateBatchPredictionOutput{}
  118. req.Data = output
  119. return
  120. }
  121. // CreateBatchPrediction API operation for Amazon Machine Learning.
  122. //
  123. // Generates predictions for a group of observations. The observations to process
  124. // exist in one or more data files referenced by a DataSource. This operation
  125. // creates a new BatchPrediction, and uses an MLModel and the data files referenced
  126. // by the DataSource as information sources.
  127. //
  128. // CreateBatchPrediction is an asynchronous operation. In response to CreateBatchPrediction,
  129. // Amazon Machine Learning (Amazon ML) immediately returns and sets the BatchPrediction
  130. // status to PENDING. After the BatchPrediction completes, Amazon ML sets the
  131. // status to COMPLETED.
  132. //
  133. // You can poll for status updates by using the GetBatchPrediction operation
  134. // and checking the Status parameter of the result. After the COMPLETED status
  135. // appears, the results are available in the location specified by the OutputUri
  136. // parameter.
  137. //
  138. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  139. // with awserr.Error's Code and Message methods to get detailed information about
  140. // the error.
  141. //
  142. // See the AWS API reference guide for Amazon Machine Learning's
  143. // API operation CreateBatchPrediction for usage and error information.
  144. //
  145. // Returned Error Codes:
  146. // * InvalidInputException
  147. // An error on the client occurred. Typically, the cause is an invalid input
  148. // value.
  149. //
  150. // * InternalServerException
  151. // An error on the server occurred when trying to process a request.
  152. //
  153. // * IdempotentParameterMismatchException
  154. // A second request to use or change an object was not allowed. This can result
  155. // from retrying a request using a parameter that was not present in the original
  156. // request.
  157. //
  158. func (c *MachineLearning) CreateBatchPrediction(input *CreateBatchPredictionInput) (*CreateBatchPredictionOutput, error) {
  159. req, out := c.CreateBatchPredictionRequest(input)
  160. err := req.Send()
  161. return out, err
  162. }
  163. const opCreateDataSourceFromRDS = "CreateDataSourceFromRDS"
  164. // CreateDataSourceFromRDSRequest generates a "aws/request.Request" representing the
  165. // client's request for the CreateDataSourceFromRDS operation. The "output" return
  166. // value can be used to capture response data after the request's "Send" method
  167. // is called.
  168. //
  169. // See CreateDataSourceFromRDS for usage and error information.
  170. //
  171. // Creating a request object using this method should be used when you want to inject
  172. // custom logic into the request's lifecycle using a custom handler, or if you want to
  173. // access properties on the request object before or after sending the request. If
  174. // you just want the service response, call the CreateDataSourceFromRDS method directly
  175. // instead.
  176. //
  177. // Note: You must call the "Send" method on the returned request object in order
  178. // to execute the request.
  179. //
  180. // // Example sending a request using the CreateDataSourceFromRDSRequest method.
  181. // req, resp := client.CreateDataSourceFromRDSRequest(params)
  182. //
  183. // err := req.Send()
  184. // if err == nil { // resp is now filled
  185. // fmt.Println(resp)
  186. // }
  187. //
  188. func (c *MachineLearning) CreateDataSourceFromRDSRequest(input *CreateDataSourceFromRDSInput) (req *request.Request, output *CreateDataSourceFromRDSOutput) {
  189. op := &request.Operation{
  190. Name: opCreateDataSourceFromRDS,
  191. HTTPMethod: "POST",
  192. HTTPPath: "/",
  193. }
  194. if input == nil {
  195. input = &CreateDataSourceFromRDSInput{}
  196. }
  197. req = c.newRequest(op, input, output)
  198. output = &CreateDataSourceFromRDSOutput{}
  199. req.Data = output
  200. return
  201. }
  202. // CreateDataSourceFromRDS API operation for Amazon Machine Learning.
  203. //
  204. // Creates a DataSource object from an Amazon Relational Database Service (http://aws.amazon.com/rds/)
  205. // (Amazon RDS). A DataSource references data that can be used to perform CreateMLModel,
  206. // CreateEvaluation, or CreateBatchPrediction operations.
  207. //
  208. // CreateDataSourceFromRDS is an asynchronous operation. In response to CreateDataSourceFromRDS,
  209. // Amazon Machine Learning (Amazon ML) immediately returns and sets the DataSource
  210. // status to PENDING. After the DataSource is created and ready for use, Amazon
  211. // ML sets the Status parameter to COMPLETED. DataSource in the COMPLETED or
  212. // PENDING state can be used only to perform >CreateMLModel>, CreateEvaluation,
  213. // or CreateBatchPrediction operations.
  214. //
  215. // If Amazon ML cannot accept the input source, it sets the Status parameter
  216. // to FAILED and includes an error message in the Message attribute of the GetDataSource
  217. // operation response.
  218. //
  219. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  220. // with awserr.Error's Code and Message methods to get detailed information about
  221. // the error.
  222. //
  223. // See the AWS API reference guide for Amazon Machine Learning's
  224. // API operation CreateDataSourceFromRDS for usage and error information.
  225. //
  226. // Returned Error Codes:
  227. // * InvalidInputException
  228. // An error on the client occurred. Typically, the cause is an invalid input
  229. // value.
  230. //
  231. // * InternalServerException
  232. // An error on the server occurred when trying to process a request.
  233. //
  234. // * IdempotentParameterMismatchException
  235. // A second request to use or change an object was not allowed. This can result
  236. // from retrying a request using a parameter that was not present in the original
  237. // request.
  238. //
  239. func (c *MachineLearning) CreateDataSourceFromRDS(input *CreateDataSourceFromRDSInput) (*CreateDataSourceFromRDSOutput, error) {
  240. req, out := c.CreateDataSourceFromRDSRequest(input)
  241. err := req.Send()
  242. return out, err
  243. }
  244. const opCreateDataSourceFromRedshift = "CreateDataSourceFromRedshift"
  245. // CreateDataSourceFromRedshiftRequest generates a "aws/request.Request" representing the
  246. // client's request for the CreateDataSourceFromRedshift operation. The "output" return
  247. // value can be used to capture response data after the request's "Send" method
  248. // is called.
  249. //
  250. // See CreateDataSourceFromRedshift for usage and error information.
  251. //
  252. // Creating a request object using this method should be used when you want to inject
  253. // custom logic into the request's lifecycle using a custom handler, or if you want to
  254. // access properties on the request object before or after sending the request. If
  255. // you just want the service response, call the CreateDataSourceFromRedshift method directly
  256. // instead.
  257. //
  258. // Note: You must call the "Send" method on the returned request object in order
  259. // to execute the request.
  260. //
  261. // // Example sending a request using the CreateDataSourceFromRedshiftRequest method.
  262. // req, resp := client.CreateDataSourceFromRedshiftRequest(params)
  263. //
  264. // err := req.Send()
  265. // if err == nil { // resp is now filled
  266. // fmt.Println(resp)
  267. // }
  268. //
  269. func (c *MachineLearning) CreateDataSourceFromRedshiftRequest(input *CreateDataSourceFromRedshiftInput) (req *request.Request, output *CreateDataSourceFromRedshiftOutput) {
  270. op := &request.Operation{
  271. Name: opCreateDataSourceFromRedshift,
  272. HTTPMethod: "POST",
  273. HTTPPath: "/",
  274. }
  275. if input == nil {
  276. input = &CreateDataSourceFromRedshiftInput{}
  277. }
  278. req = c.newRequest(op, input, output)
  279. output = &CreateDataSourceFromRedshiftOutput{}
  280. req.Data = output
  281. return
  282. }
  283. // CreateDataSourceFromRedshift API operation for Amazon Machine Learning.
  284. //
  285. // Creates a DataSource from a database hosted on an Amazon Redshift cluster.
  286. // A DataSource references data that can be used to perform either CreateMLModel,
  287. // CreateEvaluation, or CreateBatchPrediction operations.
  288. //
  289. // CreateDataSourceFromRedshift is an asynchronous operation. In response to
  290. // CreateDataSourceFromRedshift, Amazon Machine Learning (Amazon ML) immediately
  291. // returns and sets the DataSource status to PENDING. After the DataSource is
  292. // created and ready for use, Amazon ML sets the Status parameter to COMPLETED.
  293. // DataSource in COMPLETED or PENDING states can be used to perform only CreateMLModel,
  294. // CreateEvaluation, or CreateBatchPrediction operations.
  295. //
  296. // If Amazon ML can't accept the input source, it sets the Status parameter
  297. // to FAILED and includes an error message in the Message attribute of the GetDataSource
  298. // operation response.
  299. //
  300. // The observations should be contained in the database hosted on an Amazon
  301. // Redshift cluster and should be specified by a SelectSqlQuery query. Amazon
  302. // ML executes an Unload command in Amazon Redshift to transfer the result set
  303. // of the SelectSqlQuery query to S3StagingLocation.
  304. //
  305. // After the DataSource has been created, it's ready for use in evaluations
  306. // and batch predictions. If you plan to use the DataSource to train an MLModel,
  307. // the DataSource also requires a recipe. A recipe describes how each input
  308. // variable will be used in training an MLModel. Will the variable be included
  309. // or excluded from training? Will the variable be manipulated; for example,
  310. // will it be combined with another variable or will it be split apart into
  311. // word combinations? The recipe provides answers to these questions.
  312. //
  313. // You can't change an existing datasource, but you can copy and modify the
  314. // settings from an existing Amazon Redshift datasource to create a new datasource.
  315. // To do so, call GetDataSource for an existing datasource and copy the values
  316. // to a CreateDataSource call. Change the settings that you want to change and
  317. // make sure that all required fields have the appropriate values.
  318. //
  319. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  320. // with awserr.Error's Code and Message methods to get detailed information about
  321. // the error.
  322. //
  323. // See the AWS API reference guide for Amazon Machine Learning's
  324. // API operation CreateDataSourceFromRedshift for usage and error information.
  325. //
  326. // Returned Error Codes:
  327. // * InvalidInputException
  328. // An error on the client occurred. Typically, the cause is an invalid input
  329. // value.
  330. //
  331. // * InternalServerException
  332. // An error on the server occurred when trying to process a request.
  333. //
  334. // * IdempotentParameterMismatchException
  335. // A second request to use or change an object was not allowed. This can result
  336. // from retrying a request using a parameter that was not present in the original
  337. // request.
  338. //
  339. func (c *MachineLearning) CreateDataSourceFromRedshift(input *CreateDataSourceFromRedshiftInput) (*CreateDataSourceFromRedshiftOutput, error) {
  340. req, out := c.CreateDataSourceFromRedshiftRequest(input)
  341. err := req.Send()
  342. return out, err
  343. }
  344. const opCreateDataSourceFromS3 = "CreateDataSourceFromS3"
  345. // CreateDataSourceFromS3Request generates a "aws/request.Request" representing the
  346. // client's request for the CreateDataSourceFromS3 operation. The "output" return
  347. // value can be used to capture response data after the request's "Send" method
  348. // is called.
  349. //
  350. // See CreateDataSourceFromS3 for usage and error information.
  351. //
  352. // Creating a request object using this method should be used when you want to inject
  353. // custom logic into the request's lifecycle using a custom handler, or if you want to
  354. // access properties on the request object before or after sending the request. If
  355. // you just want the service response, call the CreateDataSourceFromS3 method directly
  356. // instead.
  357. //
  358. // Note: You must call the "Send" method on the returned request object in order
  359. // to execute the request.
  360. //
  361. // // Example sending a request using the CreateDataSourceFromS3Request method.
  362. // req, resp := client.CreateDataSourceFromS3Request(params)
  363. //
  364. // err := req.Send()
  365. // if err == nil { // resp is now filled
  366. // fmt.Println(resp)
  367. // }
  368. //
  369. func (c *MachineLearning) CreateDataSourceFromS3Request(input *CreateDataSourceFromS3Input) (req *request.Request, output *CreateDataSourceFromS3Output) {
  370. op := &request.Operation{
  371. Name: opCreateDataSourceFromS3,
  372. HTTPMethod: "POST",
  373. HTTPPath: "/",
  374. }
  375. if input == nil {
  376. input = &CreateDataSourceFromS3Input{}
  377. }
  378. req = c.newRequest(op, input, output)
  379. output = &CreateDataSourceFromS3Output{}
  380. req.Data = output
  381. return
  382. }
  383. // CreateDataSourceFromS3 API operation for Amazon Machine Learning.
  384. //
  385. // Creates a DataSource object. A DataSource references data that can be used
  386. // to perform CreateMLModel, CreateEvaluation, or CreateBatchPrediction operations.
  387. //
  388. // CreateDataSourceFromS3 is an asynchronous operation. In response to CreateDataSourceFromS3,
  389. // Amazon Machine Learning (Amazon ML) immediately returns and sets the DataSource
  390. // status to PENDING. After the DataSource has been created and is ready for
  391. // use, Amazon ML sets the Status parameter to COMPLETED. DataSource in the
  392. // COMPLETED or PENDING state can be used to perform only CreateMLModel, CreateEvaluation
  393. // or CreateBatchPrediction operations.
  394. //
  395. // If Amazon ML can't accept the input source, it sets the Status parameter
  396. // to FAILED and includes an error message in the Message attribute of the GetDataSource
  397. // operation response.
  398. //
  399. // The observation data used in a DataSource should be ready to use; that is,
  400. // it should have a consistent structure, and missing data values should be
  401. // kept to a minimum. The observation data must reside in one or more .csv files
  402. // in an Amazon Simple Storage Service (Amazon S3) location, along with a schema
  403. // that describes the data items by name and type. The same schema must be used
  404. // for all of the data files referenced by the DataSource.
  405. //
  406. // After the DataSource has been created, it's ready to use in evaluations and
  407. // batch predictions. If you plan to use the DataSource to train an MLModel,
  408. // the DataSource also needs a recipe. A recipe describes how each input variable
  409. // will be used in training an MLModel. Will the variable be included or excluded
  410. // from training? Will the variable be manipulated; for example, will it be
  411. // combined with another variable or will it be split apart into word combinations?
  412. // The recipe provides answers to these questions.
  413. //
  414. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  415. // with awserr.Error's Code and Message methods to get detailed information about
  416. // the error.
  417. //
  418. // See the AWS API reference guide for Amazon Machine Learning's
  419. // API operation CreateDataSourceFromS3 for usage and error information.
  420. //
  421. // Returned Error Codes:
  422. // * InvalidInputException
  423. // An error on the client occurred. Typically, the cause is an invalid input
  424. // value.
  425. //
  426. // * InternalServerException
  427. // An error on the server occurred when trying to process a request.
  428. //
  429. // * IdempotentParameterMismatchException
  430. // A second request to use or change an object was not allowed. This can result
  431. // from retrying a request using a parameter that was not present in the original
  432. // request.
  433. //
  434. func (c *MachineLearning) CreateDataSourceFromS3(input *CreateDataSourceFromS3Input) (*CreateDataSourceFromS3Output, error) {
  435. req, out := c.CreateDataSourceFromS3Request(input)
  436. err := req.Send()
  437. return out, err
  438. }
  439. const opCreateEvaluation = "CreateEvaluation"
  440. // CreateEvaluationRequest generates a "aws/request.Request" representing the
  441. // client's request for the CreateEvaluation operation. The "output" return
  442. // value can be used to capture response data after the request's "Send" method
  443. // is called.
  444. //
  445. // See CreateEvaluation for usage and error information.
  446. //
  447. // Creating a request object using this method should be used when you want to inject
  448. // custom logic into the request's lifecycle using a custom handler, or if you want to
  449. // access properties on the request object before or after sending the request. If
  450. // you just want the service response, call the CreateEvaluation method directly
  451. // instead.
  452. //
  453. // Note: You must call the "Send" method on the returned request object in order
  454. // to execute the request.
  455. //
  456. // // Example sending a request using the CreateEvaluationRequest method.
  457. // req, resp := client.CreateEvaluationRequest(params)
  458. //
  459. // err := req.Send()
  460. // if err == nil { // resp is now filled
  461. // fmt.Println(resp)
  462. // }
  463. //
  464. func (c *MachineLearning) CreateEvaluationRequest(input *CreateEvaluationInput) (req *request.Request, output *CreateEvaluationOutput) {
  465. op := &request.Operation{
  466. Name: opCreateEvaluation,
  467. HTTPMethod: "POST",
  468. HTTPPath: "/",
  469. }
  470. if input == nil {
  471. input = &CreateEvaluationInput{}
  472. }
  473. req = c.newRequest(op, input, output)
  474. output = &CreateEvaluationOutput{}
  475. req.Data = output
  476. return
  477. }
  478. // CreateEvaluation API operation for Amazon Machine Learning.
  479. //
  480. // Creates a new Evaluation of an MLModel. An MLModel is evaluated on a set
  481. // of observations associated to a DataSource. Like a DataSource for an MLModel,
  482. // the DataSource for an Evaluation contains values for the Target Variable.
  483. // The Evaluation compares the predicted result for each observation to the
  484. // actual outcome and provides a summary so that you know how effective the
  485. // MLModel functions on the test data. Evaluation generates a relevant performance
  486. // metric, such as BinaryAUC, RegressionRMSE or MulticlassAvgFScore based on
  487. // the corresponding MLModelType: BINARY, REGRESSION or MULTICLASS.
  488. //
  489. // CreateEvaluation is an asynchronous operation. In response to CreateEvaluation,
  490. // Amazon Machine Learning (Amazon ML) immediately returns and sets the evaluation
  491. // status to PENDING. After the Evaluation is created and ready for use, Amazon
  492. // ML sets the status to COMPLETED.
  493. //
  494. // You can use the GetEvaluation operation to check progress of the evaluation
  495. // during the creation operation.
  496. //
  497. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  498. // with awserr.Error's Code and Message methods to get detailed information about
  499. // the error.
  500. //
  501. // See the AWS API reference guide for Amazon Machine Learning's
  502. // API operation CreateEvaluation for usage and error information.
  503. //
  504. // Returned Error Codes:
  505. // * InvalidInputException
  506. // An error on the client occurred. Typically, the cause is an invalid input
  507. // value.
  508. //
  509. // * InternalServerException
  510. // An error on the server occurred when trying to process a request.
  511. //
  512. // * IdempotentParameterMismatchException
  513. // A second request to use or change an object was not allowed. This can result
  514. // from retrying a request using a parameter that was not present in the original
  515. // request.
  516. //
  517. func (c *MachineLearning) CreateEvaluation(input *CreateEvaluationInput) (*CreateEvaluationOutput, error) {
  518. req, out := c.CreateEvaluationRequest(input)
  519. err := req.Send()
  520. return out, err
  521. }
  522. const opCreateMLModel = "CreateMLModel"
  523. // CreateMLModelRequest generates a "aws/request.Request" representing the
  524. // client's request for the CreateMLModel operation. The "output" return
  525. // value can be used to capture response data after the request's "Send" method
  526. // is called.
  527. //
  528. // See CreateMLModel for usage and error information.
  529. //
  530. // Creating a request object using this method should be used when you want to inject
  531. // custom logic into the request's lifecycle using a custom handler, or if you want to
  532. // access properties on the request object before or after sending the request. If
  533. // you just want the service response, call the CreateMLModel method directly
  534. // instead.
  535. //
  536. // Note: You must call the "Send" method on the returned request object in order
  537. // to execute the request.
  538. //
  539. // // Example sending a request using the CreateMLModelRequest method.
  540. // req, resp := client.CreateMLModelRequest(params)
  541. //
  542. // err := req.Send()
  543. // if err == nil { // resp is now filled
  544. // fmt.Println(resp)
  545. // }
  546. //
  547. func (c *MachineLearning) CreateMLModelRequest(input *CreateMLModelInput) (req *request.Request, output *CreateMLModelOutput) {
  548. op := &request.Operation{
  549. Name: opCreateMLModel,
  550. HTTPMethod: "POST",
  551. HTTPPath: "/",
  552. }
  553. if input == nil {
  554. input = &CreateMLModelInput{}
  555. }
  556. req = c.newRequest(op, input, output)
  557. output = &CreateMLModelOutput{}
  558. req.Data = output
  559. return
  560. }
  561. // CreateMLModel API operation for Amazon Machine Learning.
  562. //
  563. // Creates a new MLModel using the DataSource and the recipe as information
  564. // sources.
  565. //
  566. // An MLModel is nearly immutable. Users can update only the MLModelName and
  567. // the ScoreThreshold in an MLModel without creating a new MLModel.
  568. //
  569. // CreateMLModel is an asynchronous operation. In response to CreateMLModel,
  570. // Amazon Machine Learning (Amazon ML) immediately returns and sets the MLModel
  571. // status to PENDING. After the MLModel has been created and ready is for use,
  572. // Amazon ML sets the status to COMPLETED.
  573. //
  574. // You can use the GetMLModel operation to check the progress of the MLModel
  575. // during the creation operation.
  576. //
  577. // CreateMLModel requires a DataSource with computed statistics, which can be
  578. // created by setting ComputeStatistics to true in CreateDataSourceFromRDS,
  579. // CreateDataSourceFromS3, or CreateDataSourceFromRedshift operations.
  580. //
  581. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  582. // with awserr.Error's Code and Message methods to get detailed information about
  583. // the error.
  584. //
  585. // See the AWS API reference guide for Amazon Machine Learning's
  586. // API operation CreateMLModel for usage and error information.
  587. //
  588. // Returned Error Codes:
  589. // * InvalidInputException
  590. // An error on the client occurred. Typically, the cause is an invalid input
  591. // value.
  592. //
  593. // * InternalServerException
  594. // An error on the server occurred when trying to process a request.
  595. //
  596. // * IdempotentParameterMismatchException
  597. // A second request to use or change an object was not allowed. This can result
  598. // from retrying a request using a parameter that was not present in the original
  599. // request.
  600. //
  601. func (c *MachineLearning) CreateMLModel(input *CreateMLModelInput) (*CreateMLModelOutput, error) {
  602. req, out := c.CreateMLModelRequest(input)
  603. err := req.Send()
  604. return out, err
  605. }
  606. const opCreateRealtimeEndpoint = "CreateRealtimeEndpoint"
  607. // CreateRealtimeEndpointRequest generates a "aws/request.Request" representing the
  608. // client's request for the CreateRealtimeEndpoint operation. The "output" return
  609. // value can be used to capture response data after the request's "Send" method
  610. // is called.
  611. //
  612. // See CreateRealtimeEndpoint for usage and error information.
  613. //
  614. // Creating a request object using this method should be used when you want to inject
  615. // custom logic into the request's lifecycle using a custom handler, or if you want to
  616. // access properties on the request object before or after sending the request. If
  617. // you just want the service response, call the CreateRealtimeEndpoint method directly
  618. // instead.
  619. //
  620. // Note: You must call the "Send" method on the returned request object in order
  621. // to execute the request.
  622. //
  623. // // Example sending a request using the CreateRealtimeEndpointRequest method.
  624. // req, resp := client.CreateRealtimeEndpointRequest(params)
  625. //
  626. // err := req.Send()
  627. // if err == nil { // resp is now filled
  628. // fmt.Println(resp)
  629. // }
  630. //
  631. func (c *MachineLearning) CreateRealtimeEndpointRequest(input *CreateRealtimeEndpointInput) (req *request.Request, output *CreateRealtimeEndpointOutput) {
  632. op := &request.Operation{
  633. Name: opCreateRealtimeEndpoint,
  634. HTTPMethod: "POST",
  635. HTTPPath: "/",
  636. }
  637. if input == nil {
  638. input = &CreateRealtimeEndpointInput{}
  639. }
  640. req = c.newRequest(op, input, output)
  641. output = &CreateRealtimeEndpointOutput{}
  642. req.Data = output
  643. return
  644. }
  645. // CreateRealtimeEndpoint API operation for Amazon Machine Learning.
  646. //
  647. // Creates a real-time endpoint for the MLModel. The endpoint contains the URI
  648. // of the MLModel; that is, the location to send real-time prediction requests
  649. // for the specified MLModel.
  650. //
  651. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  652. // with awserr.Error's Code and Message methods to get detailed information about
  653. // the error.
  654. //
  655. // See the AWS API reference guide for Amazon Machine Learning's
  656. // API operation CreateRealtimeEndpoint for usage and error information.
  657. //
  658. // Returned Error Codes:
  659. // * InvalidInputException
  660. // An error on the client occurred. Typically, the cause is an invalid input
  661. // value.
  662. //
  663. // * ResourceNotFoundException
  664. // A specified resource cannot be located.
  665. //
  666. // * InternalServerException
  667. // An error on the server occurred when trying to process a request.
  668. //
  669. func (c *MachineLearning) CreateRealtimeEndpoint(input *CreateRealtimeEndpointInput) (*CreateRealtimeEndpointOutput, error) {
  670. req, out := c.CreateRealtimeEndpointRequest(input)
  671. err := req.Send()
  672. return out, err
  673. }
  674. const opDeleteBatchPrediction = "DeleteBatchPrediction"
  675. // DeleteBatchPredictionRequest generates a "aws/request.Request" representing the
  676. // client's request for the DeleteBatchPrediction operation. The "output" return
  677. // value can be used to capture response data after the request's "Send" method
  678. // is called.
  679. //
  680. // See DeleteBatchPrediction for usage and error information.
  681. //
  682. // Creating a request object using this method should be used when you want to inject
  683. // custom logic into the request's lifecycle using a custom handler, or if you want to
  684. // access properties on the request object before or after sending the request. If
  685. // you just want the service response, call the DeleteBatchPrediction method directly
  686. // instead.
  687. //
  688. // Note: You must call the "Send" method on the returned request object in order
  689. // to execute the request.
  690. //
  691. // // Example sending a request using the DeleteBatchPredictionRequest method.
  692. // req, resp := client.DeleteBatchPredictionRequest(params)
  693. //
  694. // err := req.Send()
  695. // if err == nil { // resp is now filled
  696. // fmt.Println(resp)
  697. // }
  698. //
  699. func (c *MachineLearning) DeleteBatchPredictionRequest(input *DeleteBatchPredictionInput) (req *request.Request, output *DeleteBatchPredictionOutput) {
  700. op := &request.Operation{
  701. Name: opDeleteBatchPrediction,
  702. HTTPMethod: "POST",
  703. HTTPPath: "/",
  704. }
  705. if input == nil {
  706. input = &DeleteBatchPredictionInput{}
  707. }
  708. req = c.newRequest(op, input, output)
  709. output = &DeleteBatchPredictionOutput{}
  710. req.Data = output
  711. return
  712. }
  713. // DeleteBatchPrediction API operation for Amazon Machine Learning.
  714. //
  715. // Assigns the DELETED status to a BatchPrediction, rendering it unusable.
  716. //
  717. // After using the DeleteBatchPrediction operation, you can use the GetBatchPrediction
  718. // operation to verify that the status of the BatchPrediction changed to DELETED.
  719. //
  720. // Caution: The result of the DeleteBatchPrediction operation is irreversible.
  721. //
  722. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  723. // with awserr.Error's Code and Message methods to get detailed information about
  724. // the error.
  725. //
  726. // See the AWS API reference guide for Amazon Machine Learning's
  727. // API operation DeleteBatchPrediction for usage and error information.
  728. //
  729. // Returned Error Codes:
  730. // * InvalidInputException
  731. // An error on the client occurred. Typically, the cause is an invalid input
  732. // value.
  733. //
  734. // * ResourceNotFoundException
  735. // A specified resource cannot be located.
  736. //
  737. // * InternalServerException
  738. // An error on the server occurred when trying to process a request.
  739. //
  740. func (c *MachineLearning) DeleteBatchPrediction(input *DeleteBatchPredictionInput) (*DeleteBatchPredictionOutput, error) {
  741. req, out := c.DeleteBatchPredictionRequest(input)
  742. err := req.Send()
  743. return out, err
  744. }
  745. const opDeleteDataSource = "DeleteDataSource"
  746. // DeleteDataSourceRequest generates a "aws/request.Request" representing the
  747. // client's request for the DeleteDataSource operation. The "output" return
  748. // value can be used to capture response data after the request's "Send" method
  749. // is called.
  750. //
  751. // See DeleteDataSource for usage and error information.
  752. //
  753. // Creating a request object using this method should be used when you want to inject
  754. // custom logic into the request's lifecycle using a custom handler, or if you want to
  755. // access properties on the request object before or after sending the request. If
  756. // you just want the service response, call the DeleteDataSource method directly
  757. // instead.
  758. //
  759. // Note: You must call the "Send" method on the returned request object in order
  760. // to execute the request.
  761. //
  762. // // Example sending a request using the DeleteDataSourceRequest method.
  763. // req, resp := client.DeleteDataSourceRequest(params)
  764. //
  765. // err := req.Send()
  766. // if err == nil { // resp is now filled
  767. // fmt.Println(resp)
  768. // }
  769. //
  770. func (c *MachineLearning) DeleteDataSourceRequest(input *DeleteDataSourceInput) (req *request.Request, output *DeleteDataSourceOutput) {
  771. op := &request.Operation{
  772. Name: opDeleteDataSource,
  773. HTTPMethod: "POST",
  774. HTTPPath: "/",
  775. }
  776. if input == nil {
  777. input = &DeleteDataSourceInput{}
  778. }
  779. req = c.newRequest(op, input, output)
  780. output = &DeleteDataSourceOutput{}
  781. req.Data = output
  782. return
  783. }
  784. // DeleteDataSource API operation for Amazon Machine Learning.
  785. //
  786. // Assigns the DELETED status to a DataSource, rendering it unusable.
  787. //
  788. // After using the DeleteDataSource operation, you can use the GetDataSource
  789. // operation to verify that the status of the DataSource changed to DELETED.
  790. //
  791. // Caution: The results of the DeleteDataSource operation are irreversible.
  792. //
  793. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  794. // with awserr.Error's Code and Message methods to get detailed information about
  795. // the error.
  796. //
  797. // See the AWS API reference guide for Amazon Machine Learning's
  798. // API operation DeleteDataSource for usage and error information.
  799. //
  800. // Returned Error Codes:
  801. // * InvalidInputException
  802. // An error on the client occurred. Typically, the cause is an invalid input
  803. // value.
  804. //
  805. // * ResourceNotFoundException
  806. // A specified resource cannot be located.
  807. //
  808. // * InternalServerException
  809. // An error on the server occurred when trying to process a request.
  810. //
  811. func (c *MachineLearning) DeleteDataSource(input *DeleteDataSourceInput) (*DeleteDataSourceOutput, error) {
  812. req, out := c.DeleteDataSourceRequest(input)
  813. err := req.Send()
  814. return out, err
  815. }
  816. const opDeleteEvaluation = "DeleteEvaluation"
  817. // DeleteEvaluationRequest generates a "aws/request.Request" representing the
  818. // client's request for the DeleteEvaluation operation. The "output" return
  819. // value can be used to capture response data after the request's "Send" method
  820. // is called.
  821. //
  822. // See DeleteEvaluation for usage and error information.
  823. //
  824. // Creating a request object using this method should be used when you want to inject
  825. // custom logic into the request's lifecycle using a custom handler, or if you want to
  826. // access properties on the request object before or after sending the request. If
  827. // you just want the service response, call the DeleteEvaluation method directly
  828. // instead.
  829. //
  830. // Note: You must call the "Send" method on the returned request object in order
  831. // to execute the request.
  832. //
  833. // // Example sending a request using the DeleteEvaluationRequest method.
  834. // req, resp := client.DeleteEvaluationRequest(params)
  835. //
  836. // err := req.Send()
  837. // if err == nil { // resp is now filled
  838. // fmt.Println(resp)
  839. // }
  840. //
  841. func (c *MachineLearning) DeleteEvaluationRequest(input *DeleteEvaluationInput) (req *request.Request, output *DeleteEvaluationOutput) {
  842. op := &request.Operation{
  843. Name: opDeleteEvaluation,
  844. HTTPMethod: "POST",
  845. HTTPPath: "/",
  846. }
  847. if input == nil {
  848. input = &DeleteEvaluationInput{}
  849. }
  850. req = c.newRequest(op, input, output)
  851. output = &DeleteEvaluationOutput{}
  852. req.Data = output
  853. return
  854. }
  855. // DeleteEvaluation API operation for Amazon Machine Learning.
  856. //
  857. // Assigns the DELETED status to an Evaluation, rendering it unusable.
  858. //
  859. // After invoking the DeleteEvaluation operation, you can use the GetEvaluation
  860. // operation to verify that the status of the Evaluation changed to DELETED.
  861. //
  862. // CautionThe results of the DeleteEvaluation operation are irreversible.
  863. //
  864. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  865. // with awserr.Error's Code and Message methods to get detailed information about
  866. // the error.
  867. //
  868. // See the AWS API reference guide for Amazon Machine Learning's
  869. // API operation DeleteEvaluation for usage and error information.
  870. //
  871. // Returned Error Codes:
  872. // * InvalidInputException
  873. // An error on the client occurred. Typically, the cause is an invalid input
  874. // value.
  875. //
  876. // * ResourceNotFoundException
  877. // A specified resource cannot be located.
  878. //
  879. // * InternalServerException
  880. // An error on the server occurred when trying to process a request.
  881. //
  882. func (c *MachineLearning) DeleteEvaluation(input *DeleteEvaluationInput) (*DeleteEvaluationOutput, error) {
  883. req, out := c.DeleteEvaluationRequest(input)
  884. err := req.Send()
  885. return out, err
  886. }
  887. const opDeleteMLModel = "DeleteMLModel"
  888. // DeleteMLModelRequest generates a "aws/request.Request" representing the
  889. // client's request for the DeleteMLModel operation. The "output" return
  890. // value can be used to capture response data after the request's "Send" method
  891. // is called.
  892. //
  893. // See DeleteMLModel for usage and error information.
  894. //
  895. // Creating a request object using this method should be used when you want to inject
  896. // custom logic into the request's lifecycle using a custom handler, or if you want to
  897. // access properties on the request object before or after sending the request. If
  898. // you just want the service response, call the DeleteMLModel method directly
  899. // instead.
  900. //
  901. // Note: You must call the "Send" method on the returned request object in order
  902. // to execute the request.
  903. //
  904. // // Example sending a request using the DeleteMLModelRequest method.
  905. // req, resp := client.DeleteMLModelRequest(params)
  906. //
  907. // err := req.Send()
  908. // if err == nil { // resp is now filled
  909. // fmt.Println(resp)
  910. // }
  911. //
  912. func (c *MachineLearning) DeleteMLModelRequest(input *DeleteMLModelInput) (req *request.Request, output *DeleteMLModelOutput) {
  913. op := &request.Operation{
  914. Name: opDeleteMLModel,
  915. HTTPMethod: "POST",
  916. HTTPPath: "/",
  917. }
  918. if input == nil {
  919. input = &DeleteMLModelInput{}
  920. }
  921. req = c.newRequest(op, input, output)
  922. output = &DeleteMLModelOutput{}
  923. req.Data = output
  924. return
  925. }
  926. // DeleteMLModel API operation for Amazon Machine Learning.
  927. //
  928. // Assigns the DELETED status to an MLModel, rendering it unusable.
  929. //
  930. // After using the DeleteMLModel operation, you can use the GetMLModel operation
  931. // to verify that the status of the MLModel changed to DELETED.
  932. //
  933. // Caution: The result of the DeleteMLModel operation is irreversible.
  934. //
  935. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  936. // with awserr.Error's Code and Message methods to get detailed information about
  937. // the error.
  938. //
  939. // See the AWS API reference guide for Amazon Machine Learning's
  940. // API operation DeleteMLModel for usage and error information.
  941. //
  942. // Returned Error Codes:
  943. // * InvalidInputException
  944. // An error on the client occurred. Typically, the cause is an invalid input
  945. // value.
  946. //
  947. // * ResourceNotFoundException
  948. // A specified resource cannot be located.
  949. //
  950. // * InternalServerException
  951. // An error on the server occurred when trying to process a request.
  952. //
  953. func (c *MachineLearning) DeleteMLModel(input *DeleteMLModelInput) (*DeleteMLModelOutput, error) {
  954. req, out := c.DeleteMLModelRequest(input)
  955. err := req.Send()
  956. return out, err
  957. }
  958. const opDeleteRealtimeEndpoint = "DeleteRealtimeEndpoint"
  959. // DeleteRealtimeEndpointRequest generates a "aws/request.Request" representing the
  960. // client's request for the DeleteRealtimeEndpoint operation. The "output" return
  961. // value can be used to capture response data after the request's "Send" method
  962. // is called.
  963. //
  964. // See DeleteRealtimeEndpoint for usage and error information.
  965. //
  966. // Creating a request object using this method should be used when you want to inject
  967. // custom logic into the request's lifecycle using a custom handler, or if you want to
  968. // access properties on the request object before or after sending the request. If
  969. // you just want the service response, call the DeleteRealtimeEndpoint method directly
  970. // instead.
  971. //
  972. // Note: You must call the "Send" method on the returned request object in order
  973. // to execute the request.
  974. //
  975. // // Example sending a request using the DeleteRealtimeEndpointRequest method.
  976. // req, resp := client.DeleteRealtimeEndpointRequest(params)
  977. //
  978. // err := req.Send()
  979. // if err == nil { // resp is now filled
  980. // fmt.Println(resp)
  981. // }
  982. //
  983. func (c *MachineLearning) DeleteRealtimeEndpointRequest(input *DeleteRealtimeEndpointInput) (req *request.Request, output *DeleteRealtimeEndpointOutput) {
  984. op := &request.Operation{
  985. Name: opDeleteRealtimeEndpoint,
  986. HTTPMethod: "POST",
  987. HTTPPath: "/",
  988. }
  989. if input == nil {
  990. input = &DeleteRealtimeEndpointInput{}
  991. }
  992. req = c.newRequest(op, input, output)
  993. output = &DeleteRealtimeEndpointOutput{}
  994. req.Data = output
  995. return
  996. }
  997. // DeleteRealtimeEndpoint API operation for Amazon Machine Learning.
  998. //
  999. // Deletes a real time endpoint of an MLModel.
  1000. //
  1001. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1002. // with awserr.Error's Code and Message methods to get detailed information about
  1003. // the error.
  1004. //
  1005. // See the AWS API reference guide for Amazon Machine Learning's
  1006. // API operation DeleteRealtimeEndpoint for usage and error information.
  1007. //
  1008. // Returned Error Codes:
  1009. // * InvalidInputException
  1010. // An error on the client occurred. Typically, the cause is an invalid input
  1011. // value.
  1012. //
  1013. // * ResourceNotFoundException
  1014. // A specified resource cannot be located.
  1015. //
  1016. // * InternalServerException
  1017. // An error on the server occurred when trying to process a request.
  1018. //
  1019. func (c *MachineLearning) DeleteRealtimeEndpoint(input *DeleteRealtimeEndpointInput) (*DeleteRealtimeEndpointOutput, error) {
  1020. req, out := c.DeleteRealtimeEndpointRequest(input)
  1021. err := req.Send()
  1022. return out, err
  1023. }
  1024. const opDeleteTags = "DeleteTags"
  1025. // DeleteTagsRequest generates a "aws/request.Request" representing the
  1026. // client's request for the DeleteTags operation. The "output" return
  1027. // value can be used to capture response data after the request's "Send" method
  1028. // is called.
  1029. //
  1030. // See DeleteTags for usage and error information.
  1031. //
  1032. // Creating a request object using this method should be used when you want to inject
  1033. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1034. // access properties on the request object before or after sending the request. If
  1035. // you just want the service response, call the DeleteTags method directly
  1036. // instead.
  1037. //
  1038. // Note: You must call the "Send" method on the returned request object in order
  1039. // to execute the request.
  1040. //
  1041. // // Example sending a request using the DeleteTagsRequest method.
  1042. // req, resp := client.DeleteTagsRequest(params)
  1043. //
  1044. // err := req.Send()
  1045. // if err == nil { // resp is now filled
  1046. // fmt.Println(resp)
  1047. // }
  1048. //
  1049. func (c *MachineLearning) DeleteTagsRequest(input *DeleteTagsInput) (req *request.Request, output *DeleteTagsOutput) {
  1050. op := &request.Operation{
  1051. Name: opDeleteTags,
  1052. HTTPMethod: "POST",
  1053. HTTPPath: "/",
  1054. }
  1055. if input == nil {
  1056. input = &DeleteTagsInput{}
  1057. }
  1058. req = c.newRequest(op, input, output)
  1059. output = &DeleteTagsOutput{}
  1060. req.Data = output
  1061. return
  1062. }
  1063. // DeleteTags API operation for Amazon Machine Learning.
  1064. //
  1065. // Deletes the specified tags associated with an ML object. After this operation
  1066. // is complete, you can't recover deleted tags.
  1067. //
  1068. // If you specify a tag that doesn't exist, Amazon ML ignores it.
  1069. //
  1070. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1071. // with awserr.Error's Code and Message methods to get detailed information about
  1072. // the error.
  1073. //
  1074. // See the AWS API reference guide for Amazon Machine Learning's
  1075. // API operation DeleteTags for usage and error information.
  1076. //
  1077. // Returned Error Codes:
  1078. // * InvalidInputException
  1079. // An error on the client occurred. Typically, the cause is an invalid input
  1080. // value.
  1081. //
  1082. // * InvalidTagException
  1083. //
  1084. // * ResourceNotFoundException
  1085. // A specified resource cannot be located.
  1086. //
  1087. // * InternalServerException
  1088. // An error on the server occurred when trying to process a request.
  1089. //
  1090. func (c *MachineLearning) DeleteTags(input *DeleteTagsInput) (*DeleteTagsOutput, error) {
  1091. req, out := c.DeleteTagsRequest(input)
  1092. err := req.Send()
  1093. return out, err
  1094. }
  1095. const opDescribeBatchPredictions = "DescribeBatchPredictions"
  1096. // DescribeBatchPredictionsRequest generates a "aws/request.Request" representing the
  1097. // client's request for the DescribeBatchPredictions operation. The "output" return
  1098. // value can be used to capture response data after the request's "Send" method
  1099. // is called.
  1100. //
  1101. // See DescribeBatchPredictions for usage and error information.
  1102. //
  1103. // Creating a request object using this method should be used when you want to inject
  1104. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1105. // access properties on the request object before or after sending the request. If
  1106. // you just want the service response, call the DescribeBatchPredictions method directly
  1107. // instead.
  1108. //
  1109. // Note: You must call the "Send" method on the returned request object in order
  1110. // to execute the request.
  1111. //
  1112. // // Example sending a request using the DescribeBatchPredictionsRequest method.
  1113. // req, resp := client.DescribeBatchPredictionsRequest(params)
  1114. //
  1115. // err := req.Send()
  1116. // if err == nil { // resp is now filled
  1117. // fmt.Println(resp)
  1118. // }
  1119. //
  1120. func (c *MachineLearning) DescribeBatchPredictionsRequest(input *DescribeBatchPredictionsInput) (req *request.Request, output *DescribeBatchPredictionsOutput) {
  1121. op := &request.Operation{
  1122. Name: opDescribeBatchPredictions,
  1123. HTTPMethod: "POST",
  1124. HTTPPath: "/",
  1125. Paginator: &request.Paginator{
  1126. InputTokens: []string{"NextToken"},
  1127. OutputTokens: []string{"NextToken"},
  1128. LimitToken: "Limit",
  1129. TruncationToken: "",
  1130. },
  1131. }
  1132. if input == nil {
  1133. input = &DescribeBatchPredictionsInput{}
  1134. }
  1135. req = c.newRequest(op, input, output)
  1136. output = &DescribeBatchPredictionsOutput{}
  1137. req.Data = output
  1138. return
  1139. }
  1140. // DescribeBatchPredictions API operation for Amazon Machine Learning.
  1141. //
  1142. // Returns a list of BatchPrediction operations that match the search criteria
  1143. // in the request.
  1144. //
  1145. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1146. // with awserr.Error's Code and Message methods to get detailed information about
  1147. // the error.
  1148. //
  1149. // See the AWS API reference guide for Amazon Machine Learning's
  1150. // API operation DescribeBatchPredictions for usage and error information.
  1151. //
  1152. // Returned Error Codes:
  1153. // * InvalidInputException
  1154. // An error on the client occurred. Typically, the cause is an invalid input
  1155. // value.
  1156. //
  1157. // * InternalServerException
  1158. // An error on the server occurred when trying to process a request.
  1159. //
  1160. func (c *MachineLearning) DescribeBatchPredictions(input *DescribeBatchPredictionsInput) (*DescribeBatchPredictionsOutput, error) {
  1161. req, out := c.DescribeBatchPredictionsRequest(input)
  1162. err := req.Send()
  1163. return out, err
  1164. }
  1165. // DescribeBatchPredictionsPages iterates over the pages of a DescribeBatchPredictions operation,
  1166. // calling the "fn" function with the response data for each page. To stop
  1167. // iterating, return false from the fn function.
  1168. //
  1169. // See DescribeBatchPredictions method for more information on how to use this operation.
  1170. //
  1171. // Note: This operation can generate multiple requests to a service.
  1172. //
  1173. // // Example iterating over at most 3 pages of a DescribeBatchPredictions operation.
  1174. // pageNum := 0
  1175. // err := client.DescribeBatchPredictionsPages(params,
  1176. // func(page *DescribeBatchPredictionsOutput, lastPage bool) bool {
  1177. // pageNum++
  1178. // fmt.Println(page)
  1179. // return pageNum <= 3
  1180. // })
  1181. //
  1182. func (c *MachineLearning) DescribeBatchPredictionsPages(input *DescribeBatchPredictionsInput, fn func(p *DescribeBatchPredictionsOutput, lastPage bool) (shouldContinue bool)) error {
  1183. page, _ := c.DescribeBatchPredictionsRequest(input)
  1184. page.Handlers.Build.PushBack(request.MakeAddToUserAgentFreeFormHandler("Paginator"))
  1185. return page.EachPage(func(p interface{}, lastPage bool) bool {
  1186. return fn(p.(*DescribeBatchPredictionsOutput), lastPage)
  1187. })
  1188. }
  1189. const opDescribeDataSources = "DescribeDataSources"
  1190. // DescribeDataSourcesRequest generates a "aws/request.Request" representing the
  1191. // client's request for the DescribeDataSources operation. The "output" return
  1192. // value can be used to capture response data after the request's "Send" method
  1193. // is called.
  1194. //
  1195. // See DescribeDataSources for usage and error information.
  1196. //
  1197. // Creating a request object using this method should be used when you want to inject
  1198. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1199. // access properties on the request object before or after sending the request. If
  1200. // you just want the service response, call the DescribeDataSources method directly
  1201. // instead.
  1202. //
  1203. // Note: You must call the "Send" method on the returned request object in order
  1204. // to execute the request.
  1205. //
  1206. // // Example sending a request using the DescribeDataSourcesRequest method.
  1207. // req, resp := client.DescribeDataSourcesRequest(params)
  1208. //
  1209. // err := req.Send()
  1210. // if err == nil { // resp is now filled
  1211. // fmt.Println(resp)
  1212. // }
  1213. //
  1214. func (c *MachineLearning) DescribeDataSourcesRequest(input *DescribeDataSourcesInput) (req *request.Request, output *DescribeDataSourcesOutput) {
  1215. op := &request.Operation{
  1216. Name: opDescribeDataSources,
  1217. HTTPMethod: "POST",
  1218. HTTPPath: "/",
  1219. Paginator: &request.Paginator{
  1220. InputTokens: []string{"NextToken"},
  1221. OutputTokens: []string{"NextToken"},
  1222. LimitToken: "Limit",
  1223. TruncationToken: "",
  1224. },
  1225. }
  1226. if input == nil {
  1227. input = &DescribeDataSourcesInput{}
  1228. }
  1229. req = c.newRequest(op, input, output)
  1230. output = &DescribeDataSourcesOutput{}
  1231. req.Data = output
  1232. return
  1233. }
  1234. // DescribeDataSources API operation for Amazon Machine Learning.
  1235. //
  1236. // Returns a list of DataSource that match the search criteria in the request.
  1237. //
  1238. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1239. // with awserr.Error's Code and Message methods to get detailed information about
  1240. // the error.
  1241. //
  1242. // See the AWS API reference guide for Amazon Machine Learning's
  1243. // API operation DescribeDataSources for usage and error information.
  1244. //
  1245. // Returned Error Codes:
  1246. // * InvalidInputException
  1247. // An error on the client occurred. Typically, the cause is an invalid input
  1248. // value.
  1249. //
  1250. // * InternalServerException
  1251. // An error on the server occurred when trying to process a request.
  1252. //
  1253. func (c *MachineLearning) DescribeDataSources(input *DescribeDataSourcesInput) (*DescribeDataSourcesOutput, error) {
  1254. req, out := c.DescribeDataSourcesRequest(input)
  1255. err := req.Send()
  1256. return out, err
  1257. }
  1258. // DescribeDataSourcesPages iterates over the pages of a DescribeDataSources operation,
  1259. // calling the "fn" function with the response data for each page. To stop
  1260. // iterating, return false from the fn function.
  1261. //
  1262. // See DescribeDataSources method for more information on how to use this operation.
  1263. //
  1264. // Note: This operation can generate multiple requests to a service.
  1265. //
  1266. // // Example iterating over at most 3 pages of a DescribeDataSources operation.
  1267. // pageNum := 0
  1268. // err := client.DescribeDataSourcesPages(params,
  1269. // func(page *DescribeDataSourcesOutput, lastPage bool) bool {
  1270. // pageNum++
  1271. // fmt.Println(page)
  1272. // return pageNum <= 3
  1273. // })
  1274. //
  1275. func (c *MachineLearning) DescribeDataSourcesPages(input *DescribeDataSourcesInput, fn func(p *DescribeDataSourcesOutput, lastPage bool) (shouldContinue bool)) error {
  1276. page, _ := c.DescribeDataSourcesRequest(input)
  1277. page.Handlers.Build.PushBack(request.MakeAddToUserAgentFreeFormHandler("Paginator"))
  1278. return page.EachPage(func(p interface{}, lastPage bool) bool {
  1279. return fn(p.(*DescribeDataSourcesOutput), lastPage)
  1280. })
  1281. }
  1282. const opDescribeEvaluations = "DescribeEvaluations"
  1283. // DescribeEvaluationsRequest generates a "aws/request.Request" representing the
  1284. // client's request for the DescribeEvaluations operation. The "output" return
  1285. // value can be used to capture response data after the request's "Send" method
  1286. // is called.
  1287. //
  1288. // See DescribeEvaluations for usage and error information.
  1289. //
  1290. // Creating a request object using this method should be used when you want to inject
  1291. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1292. // access properties on the request object before or after sending the request. If
  1293. // you just want the service response, call the DescribeEvaluations method directly
  1294. // instead.
  1295. //
  1296. // Note: You must call the "Send" method on the returned request object in order
  1297. // to execute the request.
  1298. //
  1299. // // Example sending a request using the DescribeEvaluationsRequest method.
  1300. // req, resp := client.DescribeEvaluationsRequest(params)
  1301. //
  1302. // err := req.Send()
  1303. // if err == nil { // resp is now filled
  1304. // fmt.Println(resp)
  1305. // }
  1306. //
  1307. func (c *MachineLearning) DescribeEvaluationsRequest(input *DescribeEvaluationsInput) (req *request.Request, output *DescribeEvaluationsOutput) {
  1308. op := &request.Operation{
  1309. Name: opDescribeEvaluations,
  1310. HTTPMethod: "POST",
  1311. HTTPPath: "/",
  1312. Paginator: &request.Paginator{
  1313. InputTokens: []string{"NextToken"},
  1314. OutputTokens: []string{"NextToken"},
  1315. LimitToken: "Limit",
  1316. TruncationToken: "",
  1317. },
  1318. }
  1319. if input == nil {
  1320. input = &DescribeEvaluationsInput{}
  1321. }
  1322. req = c.newRequest(op, input, output)
  1323. output = &DescribeEvaluationsOutput{}
  1324. req.Data = output
  1325. return
  1326. }
  1327. // DescribeEvaluations API operation for Amazon Machine Learning.
  1328. //
  1329. // Returns a list of DescribeEvaluations that match the search criteria in the
  1330. // request.
  1331. //
  1332. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1333. // with awserr.Error's Code and Message methods to get detailed information about
  1334. // the error.
  1335. //
  1336. // See the AWS API reference guide for Amazon Machine Learning's
  1337. // API operation DescribeEvaluations for usage and error information.
  1338. //
  1339. // Returned Error Codes:
  1340. // * InvalidInputException
  1341. // An error on the client occurred. Typically, the cause is an invalid input
  1342. // value.
  1343. //
  1344. // * InternalServerException
  1345. // An error on the server occurred when trying to process a request.
  1346. //
  1347. func (c *MachineLearning) DescribeEvaluations(input *DescribeEvaluationsInput) (*DescribeEvaluationsOutput, error) {
  1348. req, out := c.DescribeEvaluationsRequest(input)
  1349. err := req.Send()
  1350. return out, err
  1351. }
  1352. // DescribeEvaluationsPages iterates over the pages of a DescribeEvaluations operation,
  1353. // calling the "fn" function with the response data for each page. To stop
  1354. // iterating, return false from the fn function.
  1355. //
  1356. // See DescribeEvaluations method for more information on how to use this operation.
  1357. //
  1358. // Note: This operation can generate multiple requests to a service.
  1359. //
  1360. // // Example iterating over at most 3 pages of a DescribeEvaluations operation.
  1361. // pageNum := 0
  1362. // err := client.DescribeEvaluationsPages(params,
  1363. // func(page *DescribeEvaluationsOutput, lastPage bool) bool {
  1364. // pageNum++
  1365. // fmt.Println(page)
  1366. // return pageNum <= 3
  1367. // })
  1368. //
  1369. func (c *MachineLearning) DescribeEvaluationsPages(input *DescribeEvaluationsInput, fn func(p *DescribeEvaluationsOutput, lastPage bool) (shouldContinue bool)) error {
  1370. page, _ := c.DescribeEvaluationsRequest(input)
  1371. page.Handlers.Build.PushBack(request.MakeAddToUserAgentFreeFormHandler("Paginator"))
  1372. return page.EachPage(func(p interface{}, lastPage bool) bool {
  1373. return fn(p.(*DescribeEvaluationsOutput), lastPage)
  1374. })
  1375. }
  1376. const opDescribeMLModels = "DescribeMLModels"
  1377. // DescribeMLModelsRequest generates a "aws/request.Request" representing the
  1378. // client's request for the DescribeMLModels operation. The "output" return
  1379. // value can be used to capture response data after the request's "Send" method
  1380. // is called.
  1381. //
  1382. // See DescribeMLModels for usage and error information.
  1383. //
  1384. // Creating a request object using this method should be used when you want to inject
  1385. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1386. // access properties on the request object before or after sending the request. If
  1387. // you just want the service response, call the DescribeMLModels method directly
  1388. // instead.
  1389. //
  1390. // Note: You must call the "Send" method on the returned request object in order
  1391. // to execute the request.
  1392. //
  1393. // // Example sending a request using the DescribeMLModelsRequest method.
  1394. // req, resp := client.DescribeMLModelsRequest(params)
  1395. //
  1396. // err := req.Send()
  1397. // if err == nil { // resp is now filled
  1398. // fmt.Println(resp)
  1399. // }
  1400. //
  1401. func (c *MachineLearning) DescribeMLModelsRequest(input *DescribeMLModelsInput) (req *request.Request, output *DescribeMLModelsOutput) {
  1402. op := &request.Operation{
  1403. Name: opDescribeMLModels,
  1404. HTTPMethod: "POST",
  1405. HTTPPath: "/",
  1406. Paginator: &request.Paginator{
  1407. InputTokens: []string{"NextToken"},
  1408. OutputTokens: []string{"NextToken"},
  1409. LimitToken: "Limit",
  1410. TruncationToken: "",
  1411. },
  1412. }
  1413. if input == nil {
  1414. input = &DescribeMLModelsInput{}
  1415. }
  1416. req = c.newRequest(op, input, output)
  1417. output = &DescribeMLModelsOutput{}
  1418. req.Data = output
  1419. return
  1420. }
  1421. // DescribeMLModels API operation for Amazon Machine Learning.
  1422. //
  1423. // Returns a list of MLModel that match the search criteria in the request.
  1424. //
  1425. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1426. // with awserr.Error's Code and Message methods to get detailed information about
  1427. // the error.
  1428. //
  1429. // See the AWS API reference guide for Amazon Machine Learning's
  1430. // API operation DescribeMLModels for usage and error information.
  1431. //
  1432. // Returned Error Codes:
  1433. // * InvalidInputException
  1434. // An error on the client occurred. Typically, the cause is an invalid input
  1435. // value.
  1436. //
  1437. // * InternalServerException
  1438. // An error on the server occurred when trying to process a request.
  1439. //
  1440. func (c *MachineLearning) DescribeMLModels(input *DescribeMLModelsInput) (*DescribeMLModelsOutput, error) {
  1441. req, out := c.DescribeMLModelsRequest(input)
  1442. err := req.Send()
  1443. return out, err
  1444. }
  1445. // DescribeMLModelsPages iterates over the pages of a DescribeMLModels operation,
  1446. // calling the "fn" function with the response data for each page. To stop
  1447. // iterating, return false from the fn function.
  1448. //
  1449. // See DescribeMLModels method for more information on how to use this operation.
  1450. //
  1451. // Note: This operation can generate multiple requests to a service.
  1452. //
  1453. // // Example iterating over at most 3 pages of a DescribeMLModels operation.
  1454. // pageNum := 0
  1455. // err := client.DescribeMLModelsPages(params,
  1456. // func(page *DescribeMLModelsOutput, lastPage bool) bool {
  1457. // pageNum++
  1458. // fmt.Println(page)
  1459. // return pageNum <= 3
  1460. // })
  1461. //
  1462. func (c *MachineLearning) DescribeMLModelsPages(input *DescribeMLModelsInput, fn func(p *DescribeMLModelsOutput, lastPage bool) (shouldContinue bool)) error {
  1463. page, _ := c.DescribeMLModelsRequest(input)
  1464. page.Handlers.Build.PushBack(request.MakeAddToUserAgentFreeFormHandler("Paginator"))
  1465. return page.EachPage(func(p interface{}, lastPage bool) bool {
  1466. return fn(p.(*DescribeMLModelsOutput), lastPage)
  1467. })
  1468. }
  1469. const opDescribeTags = "DescribeTags"
  1470. // DescribeTagsRequest generates a "aws/request.Request" representing the
  1471. // client's request for the DescribeTags operation. The "output" return
  1472. // value can be used to capture response data after the request's "Send" method
  1473. // is called.
  1474. //
  1475. // See DescribeTags for usage and error information.
  1476. //
  1477. // Creating a request object using this method should be used when you want to inject
  1478. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1479. // access properties on the request object before or after sending the request. If
  1480. // you just want the service response, call the DescribeTags method directly
  1481. // instead.
  1482. //
  1483. // Note: You must call the "Send" method on the returned request object in order
  1484. // to execute the request.
  1485. //
  1486. // // Example sending a request using the DescribeTagsRequest method.
  1487. // req, resp := client.DescribeTagsRequest(params)
  1488. //
  1489. // err := req.Send()
  1490. // if err == nil { // resp is now filled
  1491. // fmt.Println(resp)
  1492. // }
  1493. //
  1494. func (c *MachineLearning) DescribeTagsRequest(input *DescribeTagsInput) (req *request.Request, output *DescribeTagsOutput) {
  1495. op := &request.Operation{
  1496. Name: opDescribeTags,
  1497. HTTPMethod: "POST",
  1498. HTTPPath: "/",
  1499. }
  1500. if input == nil {
  1501. input = &DescribeTagsInput{}
  1502. }
  1503. req = c.newRequest(op, input, output)
  1504. output = &DescribeTagsOutput{}
  1505. req.Data = output
  1506. return
  1507. }
  1508. // DescribeTags API operation for Amazon Machine Learning.
  1509. //
  1510. // Describes one or more of the tags for your Amazon ML object.
  1511. //
  1512. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1513. // with awserr.Error's Code and Message methods to get detailed information about
  1514. // the error.
  1515. //
  1516. // See the AWS API reference guide for Amazon Machine Learning's
  1517. // API operation DescribeTags for usage and error information.
  1518. //
  1519. // Returned Error Codes:
  1520. // * InvalidInputException
  1521. // An error on the client occurred. Typically, the cause is an invalid input
  1522. // value.
  1523. //
  1524. // * ResourceNotFoundException
  1525. // A specified resource cannot be located.
  1526. //
  1527. // * InternalServerException
  1528. // An error on the server occurred when trying to process a request.
  1529. //
  1530. func (c *MachineLearning) DescribeTags(input *DescribeTagsInput) (*DescribeTagsOutput, error) {
  1531. req, out := c.DescribeTagsRequest(input)
  1532. err := req.Send()
  1533. return out, err
  1534. }
  1535. const opGetBatchPrediction = "GetBatchPrediction"
  1536. // GetBatchPredictionRequest generates a "aws/request.Request" representing the
  1537. // client's request for the GetBatchPrediction operation. The "output" return
  1538. // value can be used to capture response data after the request's "Send" method
  1539. // is called.
  1540. //
  1541. // See GetBatchPrediction for usage and error information.
  1542. //
  1543. // Creating a request object using this method should be used when you want to inject
  1544. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1545. // access properties on the request object before or after sending the request. If
  1546. // you just want the service response, call the GetBatchPrediction method directly
  1547. // instead.
  1548. //
  1549. // Note: You must call the "Send" method on the returned request object in order
  1550. // to execute the request.
  1551. //
  1552. // // Example sending a request using the GetBatchPredictionRequest method.
  1553. // req, resp := client.GetBatchPredictionRequest(params)
  1554. //
  1555. // err := req.Send()
  1556. // if err == nil { // resp is now filled
  1557. // fmt.Println(resp)
  1558. // }
  1559. //
  1560. func (c *MachineLearning) GetBatchPredictionRequest(input *GetBatchPredictionInput) (req *request.Request, output *GetBatchPredictionOutput) {
  1561. op := &request.Operation{
  1562. Name: opGetBatchPrediction,
  1563. HTTPMethod: "POST",
  1564. HTTPPath: "/",
  1565. }
  1566. if input == nil {
  1567. input = &GetBatchPredictionInput{}
  1568. }
  1569. req = c.newRequest(op, input, output)
  1570. output = &GetBatchPredictionOutput{}
  1571. req.Data = output
  1572. return
  1573. }
  1574. // GetBatchPrediction API operation for Amazon Machine Learning.
  1575. //
  1576. // Returns a BatchPrediction that includes detailed metadata, status, and data
  1577. // file information for a Batch Prediction request.
  1578. //
  1579. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1580. // with awserr.Error's Code and Message methods to get detailed information about
  1581. // the error.
  1582. //
  1583. // See the AWS API reference guide for Amazon Machine Learning's
  1584. // API operation GetBatchPrediction for usage and error information.
  1585. //
  1586. // Returned Error Codes:
  1587. // * InvalidInputException
  1588. // An error on the client occurred. Typically, the cause is an invalid input
  1589. // value.
  1590. //
  1591. // * ResourceNotFoundException
  1592. // A specified resource cannot be located.
  1593. //
  1594. // * InternalServerException
  1595. // An error on the server occurred when trying to process a request.
  1596. //
  1597. func (c *MachineLearning) GetBatchPrediction(input *GetBatchPredictionInput) (*GetBatchPredictionOutput, error) {
  1598. req, out := c.GetBatchPredictionRequest(input)
  1599. err := req.Send()
  1600. return out, err
  1601. }
  1602. const opGetDataSource = "GetDataSource"
  1603. // GetDataSourceRequest generates a "aws/request.Request" representing the
  1604. // client's request for the GetDataSource operation. The "output" return
  1605. // value can be used to capture response data after the request's "Send" method
  1606. // is called.
  1607. //
  1608. // See GetDataSource for usage and error information.
  1609. //
  1610. // Creating a request object using this method should be used when you want to inject
  1611. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1612. // access properties on the request object before or after sending the request. If
  1613. // you just want the service response, call the GetDataSource method directly
  1614. // instead.
  1615. //
  1616. // Note: You must call the "Send" method on the returned request object in order
  1617. // to execute the request.
  1618. //
  1619. // // Example sending a request using the GetDataSourceRequest method.
  1620. // req, resp := client.GetDataSourceRequest(params)
  1621. //
  1622. // err := req.Send()
  1623. // if err == nil { // resp is now filled
  1624. // fmt.Println(resp)
  1625. // }
  1626. //
  1627. func (c *MachineLearning) GetDataSourceRequest(input *GetDataSourceInput) (req *request.Request, output *GetDataSourceOutput) {
  1628. op := &request.Operation{
  1629. Name: opGetDataSource,
  1630. HTTPMethod: "POST",
  1631. HTTPPath: "/",
  1632. }
  1633. if input == nil {
  1634. input = &GetDataSourceInput{}
  1635. }
  1636. req = c.newRequest(op, input, output)
  1637. output = &GetDataSourceOutput{}
  1638. req.Data = output
  1639. return
  1640. }
  1641. // GetDataSource API operation for Amazon Machine Learning.
  1642. //
  1643. // Returns a DataSource that includes metadata and data file information, as
  1644. // well as the current status of the DataSource.
  1645. //
  1646. // GetDataSource provides results in normal or verbose format. The verbose format
  1647. // adds the schema description and the list of files pointed to by the DataSource
  1648. // to the normal format.
  1649. //
  1650. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1651. // with awserr.Error's Code and Message methods to get detailed information about
  1652. // the error.
  1653. //
  1654. // See the AWS API reference guide for Amazon Machine Learning's
  1655. // API operation GetDataSource for usage and error information.
  1656. //
  1657. // Returned Error Codes:
  1658. // * InvalidInputException
  1659. // An error on the client occurred. Typically, the cause is an invalid input
  1660. // value.
  1661. //
  1662. // * ResourceNotFoundException
  1663. // A specified resource cannot be located.
  1664. //
  1665. // * InternalServerException
  1666. // An error on the server occurred when trying to process a request.
  1667. //
  1668. func (c *MachineLearning) GetDataSource(input *GetDataSourceInput) (*GetDataSourceOutput, error) {
  1669. req, out := c.GetDataSourceRequest(input)
  1670. err := req.Send()
  1671. return out, err
  1672. }
  1673. const opGetEvaluation = "GetEvaluation"
  1674. // GetEvaluationRequest generates a "aws/request.Request" representing the
  1675. // client's request for the GetEvaluation operation. The "output" return
  1676. // value can be used to capture response data after the request's "Send" method
  1677. // is called.
  1678. //
  1679. // See GetEvaluation for usage and error information.
  1680. //
  1681. // Creating a request object using this method should be used when you want to inject
  1682. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1683. // access properties on the request object before or after sending the request. If
  1684. // you just want the service response, call the GetEvaluation method directly
  1685. // instead.
  1686. //
  1687. // Note: You must call the "Send" method on the returned request object in order
  1688. // to execute the request.
  1689. //
  1690. // // Example sending a request using the GetEvaluationRequest method.
  1691. // req, resp := client.GetEvaluationRequest(params)
  1692. //
  1693. // err := req.Send()
  1694. // if err == nil { // resp is now filled
  1695. // fmt.Println(resp)
  1696. // }
  1697. //
  1698. func (c *MachineLearning) GetEvaluationRequest(input *GetEvaluationInput) (req *request.Request, output *GetEvaluationOutput) {
  1699. op := &request.Operation{
  1700. Name: opGetEvaluation,
  1701. HTTPMethod: "POST",
  1702. HTTPPath: "/",
  1703. }
  1704. if input == nil {
  1705. input = &GetEvaluationInput{}
  1706. }
  1707. req = c.newRequest(op, input, output)
  1708. output = &GetEvaluationOutput{}
  1709. req.Data = output
  1710. return
  1711. }
  1712. // GetEvaluation API operation for Amazon Machine Learning.
  1713. //
  1714. // Returns an Evaluation that includes metadata as well as the current status
  1715. // of the Evaluation.
  1716. //
  1717. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1718. // with awserr.Error's Code and Message methods to get detailed information about
  1719. // the error.
  1720. //
  1721. // See the AWS API reference guide for Amazon Machine Learning's
  1722. // API operation GetEvaluation for usage and error information.
  1723. //
  1724. // Returned Error Codes:
  1725. // * InvalidInputException
  1726. // An error on the client occurred. Typically, the cause is an invalid input
  1727. // value.
  1728. //
  1729. // * ResourceNotFoundException
  1730. // A specified resource cannot be located.
  1731. //
  1732. // * InternalServerException
  1733. // An error on the server occurred when trying to process a request.
  1734. //
  1735. func (c *MachineLearning) GetEvaluation(input *GetEvaluationInput) (*GetEvaluationOutput, error) {
  1736. req, out := c.GetEvaluationRequest(input)
  1737. err := req.Send()
  1738. return out, err
  1739. }
  1740. const opGetMLModel = "GetMLModel"
  1741. // GetMLModelRequest generates a "aws/request.Request" representing the
  1742. // client's request for the GetMLModel operation. The "output" return
  1743. // value can be used to capture response data after the request's "Send" method
  1744. // is called.
  1745. //
  1746. // See GetMLModel for usage and error information.
  1747. //
  1748. // Creating a request object using this method should be used when you want to inject
  1749. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1750. // access properties on the request object before or after sending the request. If
  1751. // you just want the service response, call the GetMLModel method directly
  1752. // instead.
  1753. //
  1754. // Note: You must call the "Send" method on the returned request object in order
  1755. // to execute the request.
  1756. //
  1757. // // Example sending a request using the GetMLModelRequest method.
  1758. // req, resp := client.GetMLModelRequest(params)
  1759. //
  1760. // err := req.Send()
  1761. // if err == nil { // resp is now filled
  1762. // fmt.Println(resp)
  1763. // }
  1764. //
  1765. func (c *MachineLearning) GetMLModelRequest(input *GetMLModelInput) (req *request.Request, output *GetMLModelOutput) {
  1766. op := &request.Operation{
  1767. Name: opGetMLModel,
  1768. HTTPMethod: "POST",
  1769. HTTPPath: "/",
  1770. }
  1771. if input == nil {
  1772. input = &GetMLModelInput{}
  1773. }
  1774. req = c.newRequest(op, input, output)
  1775. output = &GetMLModelOutput{}
  1776. req.Data = output
  1777. return
  1778. }
  1779. // GetMLModel API operation for Amazon Machine Learning.
  1780. //
  1781. // Returns an MLModel that includes detailed metadata, data source information,
  1782. // and the current status of the MLModel.
  1783. //
  1784. // GetMLModel provides results in normal or verbose format.
  1785. //
  1786. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1787. // with awserr.Error's Code and Message methods to get detailed information about
  1788. // the error.
  1789. //
  1790. // See the AWS API reference guide for Amazon Machine Learning's
  1791. // API operation GetMLModel for usage and error information.
  1792. //
  1793. // Returned Error Codes:
  1794. // * InvalidInputException
  1795. // An error on the client occurred. Typically, the cause is an invalid input
  1796. // value.
  1797. //
  1798. // * ResourceNotFoundException
  1799. // A specified resource cannot be located.
  1800. //
  1801. // * InternalServerException
  1802. // An error on the server occurred when trying to process a request.
  1803. //
  1804. func (c *MachineLearning) GetMLModel(input *GetMLModelInput) (*GetMLModelOutput, error) {
  1805. req, out := c.GetMLModelRequest(input)
  1806. err := req.Send()
  1807. return out, err
  1808. }
  1809. const opPredict = "Predict"
  1810. // PredictRequest generates a "aws/request.Request" representing the
  1811. // client's request for the Predict operation. The "output" return
  1812. // value can be used to capture response data after the request's "Send" method
  1813. // is called.
  1814. //
  1815. // See Predict for usage and error information.
  1816. //
  1817. // Creating a request object using this method should be used when you want to inject
  1818. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1819. // access properties on the request object before or after sending the request. If
  1820. // you just want the service response, call the Predict method directly
  1821. // instead.
  1822. //
  1823. // Note: You must call the "Send" method on the returned request object in order
  1824. // to execute the request.
  1825. //
  1826. // // Example sending a request using the PredictRequest method.
  1827. // req, resp := client.PredictRequest(params)
  1828. //
  1829. // err := req.Send()
  1830. // if err == nil { // resp is now filled
  1831. // fmt.Println(resp)
  1832. // }
  1833. //
  1834. func (c *MachineLearning) PredictRequest(input *PredictInput) (req *request.Request, output *PredictOutput) {
  1835. op := &request.Operation{
  1836. Name: opPredict,
  1837. HTTPMethod: "POST",
  1838. HTTPPath: "/",
  1839. }
  1840. if input == nil {
  1841. input = &PredictInput{}
  1842. }
  1843. req = c.newRequest(op, input, output)
  1844. output = &PredictOutput{}
  1845. req.Data = output
  1846. return
  1847. }
  1848. // Predict API operation for Amazon Machine Learning.
  1849. //
  1850. // Generates a prediction for the observation using the specified ML Model.
  1851. //
  1852. // NoteNot all response parameters will be populated. Whether a response parameter
  1853. // is populated depends on the type of model requested.
  1854. //
  1855. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1856. // with awserr.Error's Code and Message methods to get detailed information about
  1857. // the error.
  1858. //
  1859. // See the AWS API reference guide for Amazon Machine Learning's
  1860. // API operation Predict for usage and error information.
  1861. //
  1862. // Returned Error Codes:
  1863. // * InvalidInputException
  1864. // An error on the client occurred. Typically, the cause is an invalid input
  1865. // value.
  1866. //
  1867. // * ResourceNotFoundException
  1868. // A specified resource cannot be located.
  1869. //
  1870. // * LimitExceededException
  1871. // The subscriber exceeded the maximum number of operations. This exception
  1872. // can occur when listing objects such as DataSource.
  1873. //
  1874. // * InternalServerException
  1875. // An error on the server occurred when trying to process a request.
  1876. //
  1877. // * PredictorNotMountedException
  1878. // The exception is thrown when a predict request is made to an unmounted MLModel.
  1879. //
  1880. func (c *MachineLearning) Predict(input *PredictInput) (*PredictOutput, error) {
  1881. req, out := c.PredictRequest(input)
  1882. err := req.Send()
  1883. return out, err
  1884. }
  1885. const opUpdateBatchPrediction = "UpdateBatchPrediction"
  1886. // UpdateBatchPredictionRequest generates a "aws/request.Request" representing the
  1887. // client's request for the UpdateBatchPrediction operation. The "output" return
  1888. // value can be used to capture response data after the request's "Send" method
  1889. // is called.
  1890. //
  1891. // See UpdateBatchPrediction for usage and error information.
  1892. //
  1893. // Creating a request object using this method should be used when you want to inject
  1894. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1895. // access properties on the request object before or after sending the request. If
  1896. // you just want the service response, call the UpdateBatchPrediction method directly
  1897. // instead.
  1898. //
  1899. // Note: You must call the "Send" method on the returned request object in order
  1900. // to execute the request.
  1901. //
  1902. // // Example sending a request using the UpdateBatchPredictionRequest method.
  1903. // req, resp := client.UpdateBatchPredictionRequest(params)
  1904. //
  1905. // err := req.Send()
  1906. // if err == nil { // resp is now filled
  1907. // fmt.Println(resp)
  1908. // }
  1909. //
  1910. func (c *MachineLearning) UpdateBatchPredictionRequest(input *UpdateBatchPredictionInput) (req *request.Request, output *UpdateBatchPredictionOutput) {
  1911. op := &request.Operation{
  1912. Name: opUpdateBatchPrediction,
  1913. HTTPMethod: "POST",
  1914. HTTPPath: "/",
  1915. }
  1916. if input == nil {
  1917. input = &UpdateBatchPredictionInput{}
  1918. }
  1919. req = c.newRequest(op, input, output)
  1920. output = &UpdateBatchPredictionOutput{}
  1921. req.Data = output
  1922. return
  1923. }
  1924. // UpdateBatchPrediction API operation for Amazon Machine Learning.
  1925. //
  1926. // Updates the BatchPredictionName of a BatchPrediction.
  1927. //
  1928. // You can use the GetBatchPrediction operation to view the contents of the
  1929. // updated data element.
  1930. //
  1931. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1932. // with awserr.Error's Code and Message methods to get detailed information about
  1933. // the error.
  1934. //
  1935. // See the AWS API reference guide for Amazon Machine Learning's
  1936. // API operation UpdateBatchPrediction for usage and error information.
  1937. //
  1938. // Returned Error Codes:
  1939. // * InvalidInputException
  1940. // An error on the client occurred. Typically, the cause is an invalid input
  1941. // value.
  1942. //
  1943. // * ResourceNotFoundException
  1944. // A specified resource cannot be located.
  1945. //
  1946. // * InternalServerException
  1947. // An error on the server occurred when trying to process a request.
  1948. //
  1949. func (c *MachineLearning) UpdateBatchPrediction(input *UpdateBatchPredictionInput) (*UpdateBatchPredictionOutput, error) {
  1950. req, out := c.UpdateBatchPredictionRequest(input)
  1951. err := req.Send()
  1952. return out, err
  1953. }
  1954. const opUpdateDataSource = "UpdateDataSource"
  1955. // UpdateDataSourceRequest generates a "aws/request.Request" representing the
  1956. // client's request for the UpdateDataSource operation. The "output" return
  1957. // value can be used to capture response data after the request's "Send" method
  1958. // is called.
  1959. //
  1960. // See UpdateDataSource for usage and error information.
  1961. //
  1962. // Creating a request object using this method should be used when you want to inject
  1963. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1964. // access properties on the request object before or after sending the request. If
  1965. // you just want the service response, call the UpdateDataSource method directly
  1966. // instead.
  1967. //
  1968. // Note: You must call the "Send" method on the returned request object in order
  1969. // to execute the request.
  1970. //
  1971. // // Example sending a request using the UpdateDataSourceRequest method.
  1972. // req, resp := client.UpdateDataSourceRequest(params)
  1973. //
  1974. // err := req.Send()
  1975. // if err == nil { // resp is now filled
  1976. // fmt.Println(resp)
  1977. // }
  1978. //
  1979. func (c *MachineLearning) UpdateDataSourceRequest(input *UpdateDataSourceInput) (req *request.Request, output *UpdateDataSourceOutput) {
  1980. op := &request.Operation{
  1981. Name: opUpdateDataSource,
  1982. HTTPMethod: "POST",
  1983. HTTPPath: "/",
  1984. }
  1985. if input == nil {
  1986. input = &UpdateDataSourceInput{}
  1987. }
  1988. req = c.newRequest(op, input, output)
  1989. output = &UpdateDataSourceOutput{}
  1990. req.Data = output
  1991. return
  1992. }
  1993. // UpdateDataSource API operation for Amazon Machine Learning.
  1994. //
  1995. // Updates the DataSourceName of a DataSource.
  1996. //
  1997. // You can use the GetDataSource operation to view the contents of the updated
  1998. // data element.
  1999. //
  2000. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2001. // with awserr.Error's Code and Message methods to get detailed information about
  2002. // the error.
  2003. //
  2004. // See the AWS API reference guide for Amazon Machine Learning's
  2005. // API operation UpdateDataSource for usage and error information.
  2006. //
  2007. // Returned Error Codes:
  2008. // * InvalidInputException
  2009. // An error on the client occurred. Typically, the cause is an invalid input
  2010. // value.
  2011. //
  2012. // * ResourceNotFoundException
  2013. // A specified resource cannot be located.
  2014. //
  2015. // * InternalServerException
  2016. // An error on the server occurred when trying to process a request.
  2017. //
  2018. func (c *MachineLearning) UpdateDataSource(input *UpdateDataSourceInput) (*UpdateDataSourceOutput, error) {
  2019. req, out := c.UpdateDataSourceRequest(input)
  2020. err := req.Send()
  2021. return out, err
  2022. }
  2023. const opUpdateEvaluation = "UpdateEvaluation"
  2024. // UpdateEvaluationRequest generates a "aws/request.Request" representing the
  2025. // client's request for the UpdateEvaluation operation. The "output" return
  2026. // value can be used to capture response data after the request's "Send" method
  2027. // is called.
  2028. //
  2029. // See UpdateEvaluation for usage and error information.
  2030. //
  2031. // Creating a request object using this method should be used when you want to inject
  2032. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2033. // access properties on the request object before or after sending the request. If
  2034. // you just want the service response, call the UpdateEvaluation method directly
  2035. // instead.
  2036. //
  2037. // Note: You must call the "Send" method on the returned request object in order
  2038. // to execute the request.
  2039. //
  2040. // // Example sending a request using the UpdateEvaluationRequest method.
  2041. // req, resp := client.UpdateEvaluationRequest(params)
  2042. //
  2043. // err := req.Send()
  2044. // if err == nil { // resp is now filled
  2045. // fmt.Println(resp)
  2046. // }
  2047. //
  2048. func (c *MachineLearning) UpdateEvaluationRequest(input *UpdateEvaluationInput) (req *request.Request, output *UpdateEvaluationOutput) {
  2049. op := &request.Operation{
  2050. Name: opUpdateEvaluation,
  2051. HTTPMethod: "POST",
  2052. HTTPPath: "/",
  2053. }
  2054. if input == nil {
  2055. input = &UpdateEvaluationInput{}
  2056. }
  2057. req = c.newRequest(op, input, output)
  2058. output = &UpdateEvaluationOutput{}
  2059. req.Data = output
  2060. return
  2061. }
  2062. // UpdateEvaluation API operation for Amazon Machine Learning.
  2063. //
  2064. // Updates the EvaluationName of an Evaluation.
  2065. //
  2066. // You can use the GetEvaluation operation to view the contents of the updated
  2067. // data element.
  2068. //
  2069. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2070. // with awserr.Error's Code and Message methods to get detailed information about
  2071. // the error.
  2072. //
  2073. // See the AWS API reference guide for Amazon Machine Learning's
  2074. // API operation UpdateEvaluation for usage and error information.
  2075. //
  2076. // Returned Error Codes:
  2077. // * InvalidInputException
  2078. // An error on the client occurred. Typically, the cause is an invalid input
  2079. // value.
  2080. //
  2081. // * ResourceNotFoundException
  2082. // A specified resource cannot be located.
  2083. //
  2084. // * InternalServerException
  2085. // An error on the server occurred when trying to process a request.
  2086. //
  2087. func (c *MachineLearning) UpdateEvaluation(input *UpdateEvaluationInput) (*UpdateEvaluationOutput, error) {
  2088. req, out := c.UpdateEvaluationRequest(input)
  2089. err := req.Send()
  2090. return out, err
  2091. }
  2092. const opUpdateMLModel = "UpdateMLModel"
  2093. // UpdateMLModelRequest generates a "aws/request.Request" representing the
  2094. // client's request for the UpdateMLModel operation. The "output" return
  2095. // value can be used to capture response data after the request's "Send" method
  2096. // is called.
  2097. //
  2098. // See UpdateMLModel for usage and error information.
  2099. //
  2100. // Creating a request object using this method should be used when you want to inject
  2101. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2102. // access properties on the request object before or after sending the request. If
  2103. // you just want the service response, call the UpdateMLModel method directly
  2104. // instead.
  2105. //
  2106. // Note: You must call the "Send" method on the returned request object in order
  2107. // to execute the request.
  2108. //
  2109. // // Example sending a request using the UpdateMLModelRequest method.
  2110. // req, resp := client.UpdateMLModelRequest(params)
  2111. //
  2112. // err := req.Send()
  2113. // if err == nil { // resp is now filled
  2114. // fmt.Println(resp)
  2115. // }
  2116. //
  2117. func (c *MachineLearning) UpdateMLModelRequest(input *UpdateMLModelInput) (req *request.Request, output *UpdateMLModelOutput) {
  2118. op := &request.Operation{
  2119. Name: opUpdateMLModel,
  2120. HTTPMethod: "POST",
  2121. HTTPPath: "/",
  2122. }
  2123. if input == nil {
  2124. input = &UpdateMLModelInput{}
  2125. }
  2126. req = c.newRequest(op, input, output)
  2127. output = &UpdateMLModelOutput{}
  2128. req.Data = output
  2129. return
  2130. }
  2131. // UpdateMLModel API operation for Amazon Machine Learning.
  2132. //
  2133. // Updates the MLModelName and the ScoreThreshold of an MLModel.
  2134. //
  2135. // You can use the GetMLModel operation to view the contents of the updated
  2136. // data element.
  2137. //
  2138. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2139. // with awserr.Error's Code and Message methods to get detailed information about
  2140. // the error.
  2141. //
  2142. // See the AWS API reference guide for Amazon Machine Learning's
  2143. // API operation UpdateMLModel for usage and error information.
  2144. //
  2145. // Returned Error Codes:
  2146. // * InvalidInputException
  2147. // An error on the client occurred. Typically, the cause is an invalid input
  2148. // value.
  2149. //
  2150. // * ResourceNotFoundException
  2151. // A specified resource cannot be located.
  2152. //
  2153. // * InternalServerException
  2154. // An error on the server occurred when trying to process a request.
  2155. //
  2156. func (c *MachineLearning) UpdateMLModel(input *UpdateMLModelInput) (*UpdateMLModelOutput, error) {
  2157. req, out := c.UpdateMLModelRequest(input)
  2158. err := req.Send()
  2159. return out, err
  2160. }
  2161. type AddTagsInput struct {
  2162. _ struct{} `type:"structure"`
  2163. // The ID of the ML object to tag. For example, exampleModelId.
  2164. //
  2165. // ResourceId is a required field
  2166. ResourceId *string `min:"1" type:"string" required:"true"`
  2167. // The type of the ML object to tag.
  2168. //
  2169. // ResourceType is a required field
  2170. ResourceType *string `type:"string" required:"true" enum:"TaggableResourceType"`
  2171. // The key-value pairs to use to create tags. If you specify a key without specifying
  2172. // a value, Amazon ML creates a tag with the specified key and a value of null.
  2173. //
  2174. // Tags is a required field
  2175. Tags []*Tag `type:"list" required:"true"`
  2176. }
  2177. // String returns the string representation
  2178. func (s AddTagsInput) String() string {
  2179. return awsutil.Prettify(s)
  2180. }
  2181. // GoString returns the string representation
  2182. func (s AddTagsInput) GoString() string {
  2183. return s.String()
  2184. }
  2185. // Validate inspects the fields of the type to determine if they are valid.
  2186. func (s *AddTagsInput) Validate() error {
  2187. invalidParams := request.ErrInvalidParams{Context: "AddTagsInput"}
  2188. if s.ResourceId == nil {
  2189. invalidParams.Add(request.NewErrParamRequired("ResourceId"))
  2190. }
  2191. if s.ResourceId != nil && len(*s.ResourceId) < 1 {
  2192. invalidParams.Add(request.NewErrParamMinLen("ResourceId", 1))
  2193. }
  2194. if s.ResourceType == nil {
  2195. invalidParams.Add(request.NewErrParamRequired("ResourceType"))
  2196. }
  2197. if s.Tags == nil {
  2198. invalidParams.Add(request.NewErrParamRequired("Tags"))
  2199. }
  2200. if s.Tags != nil {
  2201. for i, v := range s.Tags {
  2202. if v == nil {
  2203. continue
  2204. }
  2205. if err := v.Validate(); err != nil {
  2206. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
  2207. }
  2208. }
  2209. }
  2210. if invalidParams.Len() > 0 {
  2211. return invalidParams
  2212. }
  2213. return nil
  2214. }
  2215. // Amazon ML returns the following elements.
  2216. type AddTagsOutput struct {
  2217. _ struct{} `type:"structure"`
  2218. // The ID of the ML object that was tagged.
  2219. ResourceId *string `min:"1" type:"string"`
  2220. // The type of the ML object that was tagged.
  2221. ResourceType *string `type:"string" enum:"TaggableResourceType"`
  2222. }
  2223. // String returns the string representation
  2224. func (s AddTagsOutput) String() string {
  2225. return awsutil.Prettify(s)
  2226. }
  2227. // GoString returns the string representation
  2228. func (s AddTagsOutput) GoString() string {
  2229. return s.String()
  2230. }
  2231. // Represents the output of a GetBatchPrediction operation.
  2232. //
  2233. // The content consists of the detailed metadata, the status, and the data file
  2234. // information of a Batch Prediction.
  2235. type BatchPrediction struct {
  2236. _ struct{} `type:"structure"`
  2237. // The ID of the DataSource that points to the group of observations to predict.
  2238. BatchPredictionDataSourceId *string `min:"1" type:"string"`
  2239. // The ID assigned to the BatchPrediction at creation. This value should be
  2240. // identical to the value of the BatchPredictionID in the request.
  2241. BatchPredictionId *string `min:"1" type:"string"`
  2242. // Long integer type that is a 64-bit signed number.
  2243. ComputeTime *int64 `type:"long"`
  2244. // The time that the BatchPrediction was created. The time is expressed in epoch
  2245. // time.
  2246. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2247. // The AWS user account that invoked the BatchPrediction. The account type can
  2248. // be either an AWS root account or an AWS Identity and Access Management (IAM)
  2249. // user account.
  2250. CreatedByIamUser *string `type:"string"`
  2251. // A timestamp represented in epoch time.
  2252. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2253. // The location of the data file or directory in Amazon Simple Storage Service
  2254. // (Amazon S3).
  2255. InputDataLocationS3 *string `type:"string"`
  2256. // Long integer type that is a 64-bit signed number.
  2257. InvalidRecordCount *int64 `type:"long"`
  2258. // The time of the most recent edit to the BatchPrediction. The time is expressed
  2259. // in epoch time.
  2260. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2261. // The ID of the MLModel that generated predictions for the BatchPrediction
  2262. // request.
  2263. MLModelId *string `min:"1" type:"string"`
  2264. // A description of the most recent details about processing the batch prediction
  2265. // request.
  2266. Message *string `type:"string"`
  2267. // A user-supplied name or description of the BatchPrediction.
  2268. Name *string `type:"string"`
  2269. // The location of an Amazon S3 bucket or directory to receive the operation
  2270. // results. The following substrings are not allowed in the s3 key portion of
  2271. // the outputURI field: ':', '//', '/./', '/../'.
  2272. OutputUri *string `type:"string"`
  2273. // A timestamp represented in epoch time.
  2274. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2275. // The status of the BatchPrediction. This element can have one of the following
  2276. // values:
  2277. //
  2278. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  2279. // generate predictions for a batch of observations.
  2280. // * INPROGRESS - The process is underway.
  2281. // * FAILED - The request to perform a batch prediction did not run to completion.
  2282. // It is not usable.
  2283. // * COMPLETED - The batch prediction process completed successfully.
  2284. // * DELETED - The BatchPrediction is marked as deleted. It is not usable.
  2285. Status *string `type:"string" enum:"EntityStatus"`
  2286. // Long integer type that is a 64-bit signed number.
  2287. TotalRecordCount *int64 `type:"long"`
  2288. }
  2289. // String returns the string representation
  2290. func (s BatchPrediction) String() string {
  2291. return awsutil.Prettify(s)
  2292. }
  2293. // GoString returns the string representation
  2294. func (s BatchPrediction) GoString() string {
  2295. return s.String()
  2296. }
  2297. type CreateBatchPredictionInput struct {
  2298. _ struct{} `type:"structure"`
  2299. // The ID of the DataSource that points to the group of observations to predict.
  2300. //
  2301. // BatchPredictionDataSourceId is a required field
  2302. BatchPredictionDataSourceId *string `min:"1" type:"string" required:"true"`
  2303. // A user-supplied ID that uniquely identifies the BatchPrediction.
  2304. //
  2305. // BatchPredictionId is a required field
  2306. BatchPredictionId *string `min:"1" type:"string" required:"true"`
  2307. // A user-supplied name or description of the BatchPrediction. BatchPredictionName
  2308. // can only use the UTF-8 character set.
  2309. BatchPredictionName *string `type:"string"`
  2310. // The ID of the MLModel that will generate predictions for the group of observations.
  2311. //
  2312. // MLModelId is a required field
  2313. MLModelId *string `min:"1" type:"string" required:"true"`
  2314. // The location of an Amazon Simple Storage Service (Amazon S3) bucket or directory
  2315. // to store the batch prediction results. The following substrings are not allowed
  2316. // in the s3 key portion of the outputURI field: ':', '//', '/./', '/../'.
  2317. //
  2318. // Amazon ML needs permissions to store and retrieve the logs on your behalf.
  2319. // For information about how to set permissions, see the Amazon Machine Learning
  2320. // Developer Guide (http://docs.aws.amazon.com/machine-learning/latest/dg).
  2321. //
  2322. // OutputUri is a required field
  2323. OutputUri *string `type:"string" required:"true"`
  2324. }
  2325. // String returns the string representation
  2326. func (s CreateBatchPredictionInput) String() string {
  2327. return awsutil.Prettify(s)
  2328. }
  2329. // GoString returns the string representation
  2330. func (s CreateBatchPredictionInput) GoString() string {
  2331. return s.String()
  2332. }
  2333. // Validate inspects the fields of the type to determine if they are valid.
  2334. func (s *CreateBatchPredictionInput) Validate() error {
  2335. invalidParams := request.ErrInvalidParams{Context: "CreateBatchPredictionInput"}
  2336. if s.BatchPredictionDataSourceId == nil {
  2337. invalidParams.Add(request.NewErrParamRequired("BatchPredictionDataSourceId"))
  2338. }
  2339. if s.BatchPredictionDataSourceId != nil && len(*s.BatchPredictionDataSourceId) < 1 {
  2340. invalidParams.Add(request.NewErrParamMinLen("BatchPredictionDataSourceId", 1))
  2341. }
  2342. if s.BatchPredictionId == nil {
  2343. invalidParams.Add(request.NewErrParamRequired("BatchPredictionId"))
  2344. }
  2345. if s.BatchPredictionId != nil && len(*s.BatchPredictionId) < 1 {
  2346. invalidParams.Add(request.NewErrParamMinLen("BatchPredictionId", 1))
  2347. }
  2348. if s.MLModelId == nil {
  2349. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  2350. }
  2351. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  2352. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  2353. }
  2354. if s.OutputUri == nil {
  2355. invalidParams.Add(request.NewErrParamRequired("OutputUri"))
  2356. }
  2357. if invalidParams.Len() > 0 {
  2358. return invalidParams
  2359. }
  2360. return nil
  2361. }
  2362. // Represents the output of a CreateBatchPrediction operation, and is an acknowledgement
  2363. // that Amazon ML received the request.
  2364. //
  2365. // The CreateBatchPrediction operation is asynchronous. You can poll for status
  2366. // updates by using the >GetBatchPrediction operation and checking the Status
  2367. // parameter of the result.
  2368. type CreateBatchPredictionOutput struct {
  2369. _ struct{} `type:"structure"`
  2370. // A user-supplied ID that uniquely identifies the BatchPrediction. This value
  2371. // is identical to the value of the BatchPredictionId in the request.
  2372. BatchPredictionId *string `min:"1" type:"string"`
  2373. }
  2374. // String returns the string representation
  2375. func (s CreateBatchPredictionOutput) String() string {
  2376. return awsutil.Prettify(s)
  2377. }
  2378. // GoString returns the string representation
  2379. func (s CreateBatchPredictionOutput) GoString() string {
  2380. return s.String()
  2381. }
  2382. type CreateDataSourceFromRDSInput struct {
  2383. _ struct{} `type:"structure"`
  2384. // The compute statistics for a DataSource. The statistics are generated from
  2385. // the observation data referenced by a DataSource. Amazon ML uses the statistics
  2386. // internally during MLModel training. This parameter must be set to true if
  2387. // the DataSource needs to be used for MLModel training.
  2388. ComputeStatistics *bool `type:"boolean"`
  2389. // A user-supplied ID that uniquely identifies the DataSource. Typically, an
  2390. // Amazon Resource Number (ARN) becomes the ID for a DataSource.
  2391. //
  2392. // DataSourceId is a required field
  2393. DataSourceId *string `min:"1" type:"string" required:"true"`
  2394. // A user-supplied name or description of the DataSource.
  2395. DataSourceName *string `type:"string"`
  2396. // The data specification of an Amazon RDS DataSource:
  2397. //
  2398. // RDSData is a required field
  2399. RDSData *RDSDataSpec `type:"structure" required:"true"`
  2400. // The role that Amazon ML assumes on behalf of the user to create and activate
  2401. // a data pipeline in the user's account and copy data using the SelectSqlQuery
  2402. // query from Amazon RDS to Amazon S3.
  2403. //
  2404. // RoleARN is a required field
  2405. RoleARN *string `min:"1" type:"string" required:"true"`
  2406. }
  2407. // String returns the string representation
  2408. func (s CreateDataSourceFromRDSInput) String() string {
  2409. return awsutil.Prettify(s)
  2410. }
  2411. // GoString returns the string representation
  2412. func (s CreateDataSourceFromRDSInput) GoString() string {
  2413. return s.String()
  2414. }
  2415. // Validate inspects the fields of the type to determine if they are valid.
  2416. func (s *CreateDataSourceFromRDSInput) Validate() error {
  2417. invalidParams := request.ErrInvalidParams{Context: "CreateDataSourceFromRDSInput"}
  2418. if s.DataSourceId == nil {
  2419. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  2420. }
  2421. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  2422. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  2423. }
  2424. if s.RDSData == nil {
  2425. invalidParams.Add(request.NewErrParamRequired("RDSData"))
  2426. }
  2427. if s.RoleARN == nil {
  2428. invalidParams.Add(request.NewErrParamRequired("RoleARN"))
  2429. }
  2430. if s.RoleARN != nil && len(*s.RoleARN) < 1 {
  2431. invalidParams.Add(request.NewErrParamMinLen("RoleARN", 1))
  2432. }
  2433. if s.RDSData != nil {
  2434. if err := s.RDSData.Validate(); err != nil {
  2435. invalidParams.AddNested("RDSData", err.(request.ErrInvalidParams))
  2436. }
  2437. }
  2438. if invalidParams.Len() > 0 {
  2439. return invalidParams
  2440. }
  2441. return nil
  2442. }
  2443. // Represents the output of a CreateDataSourceFromRDS operation, and is an acknowledgement
  2444. // that Amazon ML received the request.
  2445. //
  2446. // The CreateDataSourceFromRDS> operation is asynchronous. You can poll for
  2447. // updates by using the GetBatchPrediction operation and checking the Status
  2448. // parameter. You can inspect the Message when Status shows up as FAILED. You
  2449. // can also check the progress of the copy operation by going to the DataPipeline
  2450. // console and looking up the pipeline using the pipelineId from the describe
  2451. // call.
  2452. type CreateDataSourceFromRDSOutput struct {
  2453. _ struct{} `type:"structure"`
  2454. // A user-supplied ID that uniquely identifies the datasource. This value should
  2455. // be identical to the value of the DataSourceID in the request.
  2456. DataSourceId *string `min:"1" type:"string"`
  2457. }
  2458. // String returns the string representation
  2459. func (s CreateDataSourceFromRDSOutput) String() string {
  2460. return awsutil.Prettify(s)
  2461. }
  2462. // GoString returns the string representation
  2463. func (s CreateDataSourceFromRDSOutput) GoString() string {
  2464. return s.String()
  2465. }
  2466. type CreateDataSourceFromRedshiftInput struct {
  2467. _ struct{} `type:"structure"`
  2468. // The compute statistics for a DataSource. The statistics are generated from
  2469. // the observation data referenced by a DataSource. Amazon ML uses the statistics
  2470. // internally during MLModel training. This parameter must be set to true if
  2471. // the DataSource needs to be used for MLModel training.
  2472. ComputeStatistics *bool `type:"boolean"`
  2473. // A user-supplied ID that uniquely identifies the DataSource.
  2474. //
  2475. // DataSourceId is a required field
  2476. DataSourceId *string `min:"1" type:"string" required:"true"`
  2477. // A user-supplied name or description of the DataSource.
  2478. DataSourceName *string `type:"string"`
  2479. // The data specification of an Amazon Redshift DataSource:
  2480. //
  2481. // * DatabaseInformation - DatabaseName - The name of the Amazon Redshift
  2482. // database.
  2483. // ClusterIdentifier - The unique ID for the Amazon Redshift cluster.
  2484. //
  2485. // * DatabaseCredentials - The AWS Identity and Access Management (IAM) credentials
  2486. // that are used to connect to the Amazon Redshift database.
  2487. //
  2488. // * SelectSqlQuery - The query that is used to retrieve the observation
  2489. // data for the Datasource.
  2490. //
  2491. // * S3StagingLocation - The Amazon Simple Storage Service (Amazon S3) location
  2492. // for staging Amazon Redshift data. The data retrieved from Amazon Redshift
  2493. // using the SelectSqlQuery query is stored in this location.
  2494. //
  2495. // * DataSchemaUri - The Amazon S3 location of the DataSchema.
  2496. //
  2497. // * DataSchema - A JSON string representing the schema. This is not required
  2498. // if DataSchemaUri is specified.
  2499. //
  2500. // * DataRearrangement - A JSON string that represents the splitting and
  2501. // rearrangement requirements for the DataSource.
  2502. //
  2503. // Sample - "{\"splitting\":{\"percentBegin\":10,\"percentEnd\":60}}"
  2504. //
  2505. // DataSpec is a required field
  2506. DataSpec *RedshiftDataSpec `type:"structure" required:"true"`
  2507. // A fully specified role Amazon Resource Name (ARN). Amazon ML assumes the
  2508. // role on behalf of the user to create the following:
  2509. //
  2510. // A security group to allow Amazon ML to execute the SelectSqlQuery query on
  2511. // an Amazon Redshift cluster
  2512. //
  2513. // An Amazon S3 bucket policy to grant Amazon ML read/write permissions on the
  2514. // S3StagingLocation
  2515. //
  2516. // RoleARN is a required field
  2517. RoleARN *string `min:"1" type:"string" required:"true"`
  2518. }
  2519. // String returns the string representation
  2520. func (s CreateDataSourceFromRedshiftInput) String() string {
  2521. return awsutil.Prettify(s)
  2522. }
  2523. // GoString returns the string representation
  2524. func (s CreateDataSourceFromRedshiftInput) GoString() string {
  2525. return s.String()
  2526. }
  2527. // Validate inspects the fields of the type to determine if they are valid.
  2528. func (s *CreateDataSourceFromRedshiftInput) Validate() error {
  2529. invalidParams := request.ErrInvalidParams{Context: "CreateDataSourceFromRedshiftInput"}
  2530. if s.DataSourceId == nil {
  2531. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  2532. }
  2533. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  2534. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  2535. }
  2536. if s.DataSpec == nil {
  2537. invalidParams.Add(request.NewErrParamRequired("DataSpec"))
  2538. }
  2539. if s.RoleARN == nil {
  2540. invalidParams.Add(request.NewErrParamRequired("RoleARN"))
  2541. }
  2542. if s.RoleARN != nil && len(*s.RoleARN) < 1 {
  2543. invalidParams.Add(request.NewErrParamMinLen("RoleARN", 1))
  2544. }
  2545. if s.DataSpec != nil {
  2546. if err := s.DataSpec.Validate(); err != nil {
  2547. invalidParams.AddNested("DataSpec", err.(request.ErrInvalidParams))
  2548. }
  2549. }
  2550. if invalidParams.Len() > 0 {
  2551. return invalidParams
  2552. }
  2553. return nil
  2554. }
  2555. // Represents the output of a CreateDataSourceFromRedshift operation, and is
  2556. // an acknowledgement that Amazon ML received the request.
  2557. //
  2558. // The CreateDataSourceFromRedshift operation is asynchronous. You can poll
  2559. // for updates by using the GetBatchPrediction operation and checking the Status
  2560. // parameter.
  2561. type CreateDataSourceFromRedshiftOutput struct {
  2562. _ struct{} `type:"structure"`
  2563. // A user-supplied ID that uniquely identifies the datasource. This value should
  2564. // be identical to the value of the DataSourceID in the request.
  2565. DataSourceId *string `min:"1" type:"string"`
  2566. }
  2567. // String returns the string representation
  2568. func (s CreateDataSourceFromRedshiftOutput) String() string {
  2569. return awsutil.Prettify(s)
  2570. }
  2571. // GoString returns the string representation
  2572. func (s CreateDataSourceFromRedshiftOutput) GoString() string {
  2573. return s.String()
  2574. }
  2575. type CreateDataSourceFromS3Input struct {
  2576. _ struct{} `type:"structure"`
  2577. // The compute statistics for a DataSource. The statistics are generated from
  2578. // the observation data referenced by a DataSource. Amazon ML uses the statistics
  2579. // internally during MLModel training. This parameter must be set to true if
  2580. // the DataSource needs to be used for MLModel training.
  2581. ComputeStatistics *bool `type:"boolean"`
  2582. // A user-supplied identifier that uniquely identifies the DataSource.
  2583. //
  2584. // DataSourceId is a required field
  2585. DataSourceId *string `min:"1" type:"string" required:"true"`
  2586. // A user-supplied name or description of the DataSource.
  2587. DataSourceName *string `type:"string"`
  2588. // The data specification of a DataSource:
  2589. //
  2590. // * DataLocationS3 - The Amazon S3 location of the observation data.
  2591. //
  2592. // * DataSchemaLocationS3 - The Amazon S3 location of the DataSchema.
  2593. //
  2594. // * DataSchema - A JSON string representing the schema. This is not required
  2595. // if DataSchemaUri is specified.
  2596. //
  2597. // * DataRearrangement - A JSON string that represents the splitting and
  2598. // rearrangement requirements for the Datasource.
  2599. //
  2600. // Sample - "{\"splitting\":{\"percentBegin\":10,\"percentEnd\":60}}"
  2601. //
  2602. // DataSpec is a required field
  2603. DataSpec *S3DataSpec `type:"structure" required:"true"`
  2604. }
  2605. // String returns the string representation
  2606. func (s CreateDataSourceFromS3Input) String() string {
  2607. return awsutil.Prettify(s)
  2608. }
  2609. // GoString returns the string representation
  2610. func (s CreateDataSourceFromS3Input) GoString() string {
  2611. return s.String()
  2612. }
  2613. // Validate inspects the fields of the type to determine if they are valid.
  2614. func (s *CreateDataSourceFromS3Input) Validate() error {
  2615. invalidParams := request.ErrInvalidParams{Context: "CreateDataSourceFromS3Input"}
  2616. if s.DataSourceId == nil {
  2617. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  2618. }
  2619. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  2620. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  2621. }
  2622. if s.DataSpec == nil {
  2623. invalidParams.Add(request.NewErrParamRequired("DataSpec"))
  2624. }
  2625. if s.DataSpec != nil {
  2626. if err := s.DataSpec.Validate(); err != nil {
  2627. invalidParams.AddNested("DataSpec", err.(request.ErrInvalidParams))
  2628. }
  2629. }
  2630. if invalidParams.Len() > 0 {
  2631. return invalidParams
  2632. }
  2633. return nil
  2634. }
  2635. // Represents the output of a CreateDataSourceFromS3 operation, and is an acknowledgement
  2636. // that Amazon ML received the request.
  2637. //
  2638. // The CreateDataSourceFromS3 operation is asynchronous. You can poll for updates
  2639. // by using the GetBatchPrediction operation and checking the Status parameter.
  2640. type CreateDataSourceFromS3Output struct {
  2641. _ struct{} `type:"structure"`
  2642. // A user-supplied ID that uniquely identifies the DataSource. This value should
  2643. // be identical to the value of the DataSourceID in the request.
  2644. DataSourceId *string `min:"1" type:"string"`
  2645. }
  2646. // String returns the string representation
  2647. func (s CreateDataSourceFromS3Output) String() string {
  2648. return awsutil.Prettify(s)
  2649. }
  2650. // GoString returns the string representation
  2651. func (s CreateDataSourceFromS3Output) GoString() string {
  2652. return s.String()
  2653. }
  2654. type CreateEvaluationInput struct {
  2655. _ struct{} `type:"structure"`
  2656. // The ID of the DataSource for the evaluation. The schema of the DataSource
  2657. // must match the schema used to create the MLModel.
  2658. //
  2659. // EvaluationDataSourceId is a required field
  2660. EvaluationDataSourceId *string `min:"1" type:"string" required:"true"`
  2661. // A user-supplied ID that uniquely identifies the Evaluation.
  2662. //
  2663. // EvaluationId is a required field
  2664. EvaluationId *string `min:"1" type:"string" required:"true"`
  2665. // A user-supplied name or description of the Evaluation.
  2666. EvaluationName *string `type:"string"`
  2667. // The ID of the MLModel to evaluate.
  2668. //
  2669. // The schema used in creating the MLModel must match the schema of the DataSource
  2670. // used in the Evaluation.
  2671. //
  2672. // MLModelId is a required field
  2673. MLModelId *string `min:"1" type:"string" required:"true"`
  2674. }
  2675. // String returns the string representation
  2676. func (s CreateEvaluationInput) String() string {
  2677. return awsutil.Prettify(s)
  2678. }
  2679. // GoString returns the string representation
  2680. func (s CreateEvaluationInput) GoString() string {
  2681. return s.String()
  2682. }
  2683. // Validate inspects the fields of the type to determine if they are valid.
  2684. func (s *CreateEvaluationInput) Validate() error {
  2685. invalidParams := request.ErrInvalidParams{Context: "CreateEvaluationInput"}
  2686. if s.EvaluationDataSourceId == nil {
  2687. invalidParams.Add(request.NewErrParamRequired("EvaluationDataSourceId"))
  2688. }
  2689. if s.EvaluationDataSourceId != nil && len(*s.EvaluationDataSourceId) < 1 {
  2690. invalidParams.Add(request.NewErrParamMinLen("EvaluationDataSourceId", 1))
  2691. }
  2692. if s.EvaluationId == nil {
  2693. invalidParams.Add(request.NewErrParamRequired("EvaluationId"))
  2694. }
  2695. if s.EvaluationId != nil && len(*s.EvaluationId) < 1 {
  2696. invalidParams.Add(request.NewErrParamMinLen("EvaluationId", 1))
  2697. }
  2698. if s.MLModelId == nil {
  2699. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  2700. }
  2701. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  2702. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  2703. }
  2704. if invalidParams.Len() > 0 {
  2705. return invalidParams
  2706. }
  2707. return nil
  2708. }
  2709. // Represents the output of a CreateEvaluation operation, and is an acknowledgement
  2710. // that Amazon ML received the request.
  2711. //
  2712. // CreateEvaluation operation is asynchronous. You can poll for status updates
  2713. // by using the GetEvcaluation operation and checking the Status parameter.
  2714. type CreateEvaluationOutput struct {
  2715. _ struct{} `type:"structure"`
  2716. // The user-supplied ID that uniquely identifies the Evaluation. This value
  2717. // should be identical to the value of the EvaluationId in the request.
  2718. EvaluationId *string `min:"1" type:"string"`
  2719. }
  2720. // String returns the string representation
  2721. func (s CreateEvaluationOutput) String() string {
  2722. return awsutil.Prettify(s)
  2723. }
  2724. // GoString returns the string representation
  2725. func (s CreateEvaluationOutput) GoString() string {
  2726. return s.String()
  2727. }
  2728. type CreateMLModelInput struct {
  2729. _ struct{} `type:"structure"`
  2730. // A user-supplied ID that uniquely identifies the MLModel.
  2731. //
  2732. // MLModelId is a required field
  2733. MLModelId *string `min:"1" type:"string" required:"true"`
  2734. // A user-supplied name or description of the MLModel.
  2735. MLModelName *string `type:"string"`
  2736. // The category of supervised learning that this MLModel will address. Choose
  2737. // from the following types:
  2738. //
  2739. // * Choose REGRESSION if the MLModel will be used to predict a numeric value.
  2740. //
  2741. // * Choose BINARY if the MLModel result has two possible values.
  2742. // * Choose MULTICLASS if the MLModel result has a limited number of values.
  2743. //
  2744. // For more information, see the Amazon Machine Learning Developer Guide (http://docs.aws.amazon.com/machine-learning/latest/dg).
  2745. //
  2746. // MLModelType is a required field
  2747. MLModelType *string `type:"string" required:"true" enum:"MLModelType"`
  2748. // A list of the training parameters in the MLModel. The list is implemented
  2749. // as a map of key-value pairs.
  2750. //
  2751. // The following is the current set of training parameters:
  2752. //
  2753. // * sgd.maxMLModelSizeInBytes - The maximum allowed size of the model. Depending
  2754. // on the input data, the size of the model might affect its performance.
  2755. //
  2756. // The value is an integer that ranges from 100000 to 2147483648. The default
  2757. // value is 33554432.
  2758. //
  2759. // * sgd.maxPasses - The number of times that the training process traverses
  2760. // the observations to build the MLModel. The value is an integer that ranges
  2761. // from 1 to 10000. The default value is 10.
  2762. //
  2763. // * sgd.shuffleType - Whether Amazon ML shuffles the training data. Shuffling
  2764. // the data improves a model's ability to find the optimal solution for a
  2765. // variety of data types. The valid values are auto and none. The default
  2766. // value is none. We strongly recommend that you shuffle your data.
  2767. //
  2768. // * sgd.l1RegularizationAmount - The coefficient regularization L1 norm.
  2769. // It controls overfitting the data by penalizing large coefficients. This
  2770. // tends to drive coefficients to zero, resulting in a sparse feature set.
  2771. // If you use this parameter, start by specifying a small value, such as
  2772. // 1.0E-08.
  2773. //
  2774. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  2775. // not use L1 normalization. This parameter can't be used when L2 is specified.
  2776. // Use this parameter sparingly.
  2777. //
  2778. // * sgd.l2RegularizationAmount - The coefficient regularization L2 norm.
  2779. // It controls overfitting the data by penalizing large coefficients. This
  2780. // tends to drive coefficients to small, nonzero values. If you use this
  2781. // parameter, start by specifying a small value, such as 1.0E-08.
  2782. //
  2783. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  2784. // not use L2 normalization. This parameter can't be used when L1 is specified.
  2785. // Use this parameter sparingly.
  2786. Parameters map[string]*string `type:"map"`
  2787. // The data recipe for creating the MLModel. You must specify either the recipe
  2788. // or its URI. If you don't specify a recipe or its URI, Amazon ML creates a
  2789. // default.
  2790. Recipe *string `type:"string"`
  2791. // The Amazon Simple Storage Service (Amazon S3) location and file name that
  2792. // contains the MLModel recipe. You must specify either the recipe or its URI.
  2793. // If you don't specify a recipe or its URI, Amazon ML creates a default.
  2794. RecipeUri *string `type:"string"`
  2795. // The DataSource that points to the training data.
  2796. //
  2797. // TrainingDataSourceId is a required field
  2798. TrainingDataSourceId *string `min:"1" type:"string" required:"true"`
  2799. }
  2800. // String returns the string representation
  2801. func (s CreateMLModelInput) String() string {
  2802. return awsutil.Prettify(s)
  2803. }
  2804. // GoString returns the string representation
  2805. func (s CreateMLModelInput) GoString() string {
  2806. return s.String()
  2807. }
  2808. // Validate inspects the fields of the type to determine if they are valid.
  2809. func (s *CreateMLModelInput) Validate() error {
  2810. invalidParams := request.ErrInvalidParams{Context: "CreateMLModelInput"}
  2811. if s.MLModelId == nil {
  2812. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  2813. }
  2814. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  2815. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  2816. }
  2817. if s.MLModelType == nil {
  2818. invalidParams.Add(request.NewErrParamRequired("MLModelType"))
  2819. }
  2820. if s.TrainingDataSourceId == nil {
  2821. invalidParams.Add(request.NewErrParamRequired("TrainingDataSourceId"))
  2822. }
  2823. if s.TrainingDataSourceId != nil && len(*s.TrainingDataSourceId) < 1 {
  2824. invalidParams.Add(request.NewErrParamMinLen("TrainingDataSourceId", 1))
  2825. }
  2826. if invalidParams.Len() > 0 {
  2827. return invalidParams
  2828. }
  2829. return nil
  2830. }
  2831. // Represents the output of a CreateMLModel operation, and is an acknowledgement
  2832. // that Amazon ML received the request.
  2833. //
  2834. // The CreateMLModel operation is asynchronous. You can poll for status updates
  2835. // by using the GetMLModel operation and checking the Status parameter.
  2836. type CreateMLModelOutput struct {
  2837. _ struct{} `type:"structure"`
  2838. // A user-supplied ID that uniquely identifies the MLModel. This value should
  2839. // be identical to the value of the MLModelId in the request.
  2840. MLModelId *string `min:"1" type:"string"`
  2841. }
  2842. // String returns the string representation
  2843. func (s CreateMLModelOutput) String() string {
  2844. return awsutil.Prettify(s)
  2845. }
  2846. // GoString returns the string representation
  2847. func (s CreateMLModelOutput) GoString() string {
  2848. return s.String()
  2849. }
  2850. type CreateRealtimeEndpointInput struct {
  2851. _ struct{} `type:"structure"`
  2852. // The ID assigned to the MLModel during creation.
  2853. //
  2854. // MLModelId is a required field
  2855. MLModelId *string `min:"1" type:"string" required:"true"`
  2856. }
  2857. // String returns the string representation
  2858. func (s CreateRealtimeEndpointInput) String() string {
  2859. return awsutil.Prettify(s)
  2860. }
  2861. // GoString returns the string representation
  2862. func (s CreateRealtimeEndpointInput) GoString() string {
  2863. return s.String()
  2864. }
  2865. // Validate inspects the fields of the type to determine if they are valid.
  2866. func (s *CreateRealtimeEndpointInput) Validate() error {
  2867. invalidParams := request.ErrInvalidParams{Context: "CreateRealtimeEndpointInput"}
  2868. if s.MLModelId == nil {
  2869. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  2870. }
  2871. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  2872. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  2873. }
  2874. if invalidParams.Len() > 0 {
  2875. return invalidParams
  2876. }
  2877. return nil
  2878. }
  2879. // Represents the output of an CreateRealtimeEndpoint operation.
  2880. //
  2881. // The result contains the MLModelId and the endpoint information for the MLModel.
  2882. //
  2883. // The endpoint information includes the URI of the MLModel; that is, the location
  2884. // to send online prediction requests for the specified MLModel.
  2885. type CreateRealtimeEndpointOutput struct {
  2886. _ struct{} `type:"structure"`
  2887. // A user-supplied ID that uniquely identifies the MLModel. This value should
  2888. // be identical to the value of the MLModelId in the request.
  2889. MLModelId *string `min:"1" type:"string"`
  2890. // The endpoint information of the MLModel
  2891. RealtimeEndpointInfo *RealtimeEndpointInfo `type:"structure"`
  2892. }
  2893. // String returns the string representation
  2894. func (s CreateRealtimeEndpointOutput) String() string {
  2895. return awsutil.Prettify(s)
  2896. }
  2897. // GoString returns the string representation
  2898. func (s CreateRealtimeEndpointOutput) GoString() string {
  2899. return s.String()
  2900. }
  2901. // Represents the output of the GetDataSource operation.
  2902. //
  2903. // The content consists of the detailed metadata and data file information and
  2904. // the current status of the DataSource.
  2905. type DataSource struct {
  2906. _ struct{} `type:"structure"`
  2907. // The parameter is true if statistics need to be generated from the observation
  2908. // data.
  2909. ComputeStatistics *bool `type:"boolean"`
  2910. // Long integer type that is a 64-bit signed number.
  2911. ComputeTime *int64 `type:"long"`
  2912. // The time that the DataSource was created. The time is expressed in epoch
  2913. // time.
  2914. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2915. // The AWS user account from which the DataSource was created. The account type
  2916. // can be either an AWS root account or an AWS Identity and Access Management
  2917. // (IAM) user account.
  2918. CreatedByIamUser *string `type:"string"`
  2919. // The location and name of the data in Amazon Simple Storage Service (Amazon
  2920. // S3) that is used by a DataSource.
  2921. DataLocationS3 *string `type:"string"`
  2922. // A JSON string that represents the splitting and rearrangement requirement
  2923. // used when this DataSource was created.
  2924. DataRearrangement *string `type:"string"`
  2925. // The total number of observations contained in the data files that the DataSource
  2926. // references.
  2927. DataSizeInBytes *int64 `type:"long"`
  2928. // The ID that is assigned to the DataSource during creation.
  2929. DataSourceId *string `min:"1" type:"string"`
  2930. // A timestamp represented in epoch time.
  2931. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2932. // The time of the most recent edit to the BatchPrediction. The time is expressed
  2933. // in epoch time.
  2934. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2935. // A description of the most recent details about creating the DataSource.
  2936. Message *string `type:"string"`
  2937. // A user-supplied name or description of the DataSource.
  2938. Name *string `type:"string"`
  2939. // The number of data files referenced by the DataSource.
  2940. NumberOfFiles *int64 `type:"long"`
  2941. // The datasource details that are specific to Amazon RDS.
  2942. RDSMetadata *RDSMetadata `type:"structure"`
  2943. // Describes the DataSource details specific to Amazon Redshift.
  2944. RedshiftMetadata *RedshiftMetadata `type:"structure"`
  2945. // The Amazon Resource Name (ARN) of an AWS IAM Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts),
  2946. // such as the following: arn:aws:iam::account:role/rolename.
  2947. RoleARN *string `min:"1" type:"string"`
  2948. // A timestamp represented in epoch time.
  2949. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  2950. // The current status of the DataSource. This element can have one of the following
  2951. // values:
  2952. //
  2953. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  2954. // create a DataSource.
  2955. // * INPROGRESS - The creation process is underway.
  2956. // * FAILED - The request to create a DataSource did not run to completion.
  2957. // It is not usable.
  2958. // * COMPLETED - The creation process completed successfully.
  2959. // * DELETED - The DataSource is marked as deleted. It is not usable.
  2960. Status *string `type:"string" enum:"EntityStatus"`
  2961. }
  2962. // String returns the string representation
  2963. func (s DataSource) String() string {
  2964. return awsutil.Prettify(s)
  2965. }
  2966. // GoString returns the string representation
  2967. func (s DataSource) GoString() string {
  2968. return s.String()
  2969. }
  2970. type DeleteBatchPredictionInput struct {
  2971. _ struct{} `type:"structure"`
  2972. // A user-supplied ID that uniquely identifies the BatchPrediction.
  2973. //
  2974. // BatchPredictionId is a required field
  2975. BatchPredictionId *string `min:"1" type:"string" required:"true"`
  2976. }
  2977. // String returns the string representation
  2978. func (s DeleteBatchPredictionInput) String() string {
  2979. return awsutil.Prettify(s)
  2980. }
  2981. // GoString returns the string representation
  2982. func (s DeleteBatchPredictionInput) GoString() string {
  2983. return s.String()
  2984. }
  2985. // Validate inspects the fields of the type to determine if they are valid.
  2986. func (s *DeleteBatchPredictionInput) Validate() error {
  2987. invalidParams := request.ErrInvalidParams{Context: "DeleteBatchPredictionInput"}
  2988. if s.BatchPredictionId == nil {
  2989. invalidParams.Add(request.NewErrParamRequired("BatchPredictionId"))
  2990. }
  2991. if s.BatchPredictionId != nil && len(*s.BatchPredictionId) < 1 {
  2992. invalidParams.Add(request.NewErrParamMinLen("BatchPredictionId", 1))
  2993. }
  2994. if invalidParams.Len() > 0 {
  2995. return invalidParams
  2996. }
  2997. return nil
  2998. }
  2999. // Represents the output of a DeleteBatchPrediction operation.
  3000. //
  3001. // You can use the GetBatchPrediction operation and check the value of the Status
  3002. // parameter to see whether a BatchPrediction is marked as DELETED.
  3003. type DeleteBatchPredictionOutput struct {
  3004. _ struct{} `type:"structure"`
  3005. // A user-supplied ID that uniquely identifies the BatchPrediction. This value
  3006. // should be identical to the value of the BatchPredictionID in the request.
  3007. BatchPredictionId *string `min:"1" type:"string"`
  3008. }
  3009. // String returns the string representation
  3010. func (s DeleteBatchPredictionOutput) String() string {
  3011. return awsutil.Prettify(s)
  3012. }
  3013. // GoString returns the string representation
  3014. func (s DeleteBatchPredictionOutput) GoString() string {
  3015. return s.String()
  3016. }
  3017. type DeleteDataSourceInput struct {
  3018. _ struct{} `type:"structure"`
  3019. // A user-supplied ID that uniquely identifies the DataSource.
  3020. //
  3021. // DataSourceId is a required field
  3022. DataSourceId *string `min:"1" type:"string" required:"true"`
  3023. }
  3024. // String returns the string representation
  3025. func (s DeleteDataSourceInput) String() string {
  3026. return awsutil.Prettify(s)
  3027. }
  3028. // GoString returns the string representation
  3029. func (s DeleteDataSourceInput) GoString() string {
  3030. return s.String()
  3031. }
  3032. // Validate inspects the fields of the type to determine if they are valid.
  3033. func (s *DeleteDataSourceInput) Validate() error {
  3034. invalidParams := request.ErrInvalidParams{Context: "DeleteDataSourceInput"}
  3035. if s.DataSourceId == nil {
  3036. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  3037. }
  3038. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  3039. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  3040. }
  3041. if invalidParams.Len() > 0 {
  3042. return invalidParams
  3043. }
  3044. return nil
  3045. }
  3046. // Represents the output of a DeleteDataSource operation.
  3047. type DeleteDataSourceOutput struct {
  3048. _ struct{} `type:"structure"`
  3049. // A user-supplied ID that uniquely identifies the DataSource. This value should
  3050. // be identical to the value of the DataSourceID in the request.
  3051. DataSourceId *string `min:"1" type:"string"`
  3052. }
  3053. // String returns the string representation
  3054. func (s DeleteDataSourceOutput) String() string {
  3055. return awsutil.Prettify(s)
  3056. }
  3057. // GoString returns the string representation
  3058. func (s DeleteDataSourceOutput) GoString() string {
  3059. return s.String()
  3060. }
  3061. type DeleteEvaluationInput struct {
  3062. _ struct{} `type:"structure"`
  3063. // A user-supplied ID that uniquely identifies the Evaluation to delete.
  3064. //
  3065. // EvaluationId is a required field
  3066. EvaluationId *string `min:"1" type:"string" required:"true"`
  3067. }
  3068. // String returns the string representation
  3069. func (s DeleteEvaluationInput) String() string {
  3070. return awsutil.Prettify(s)
  3071. }
  3072. // GoString returns the string representation
  3073. func (s DeleteEvaluationInput) GoString() string {
  3074. return s.String()
  3075. }
  3076. // Validate inspects the fields of the type to determine if they are valid.
  3077. func (s *DeleteEvaluationInput) Validate() error {
  3078. invalidParams := request.ErrInvalidParams{Context: "DeleteEvaluationInput"}
  3079. if s.EvaluationId == nil {
  3080. invalidParams.Add(request.NewErrParamRequired("EvaluationId"))
  3081. }
  3082. if s.EvaluationId != nil && len(*s.EvaluationId) < 1 {
  3083. invalidParams.Add(request.NewErrParamMinLen("EvaluationId", 1))
  3084. }
  3085. if invalidParams.Len() > 0 {
  3086. return invalidParams
  3087. }
  3088. return nil
  3089. }
  3090. // Represents the output of a DeleteEvaluation operation. The output indicates
  3091. // that Amazon Machine Learning (Amazon ML) received the request.
  3092. //
  3093. // You can use the GetEvaluation operation and check the value of the Status
  3094. // parameter to see whether an Evaluation is marked as DELETED.
  3095. type DeleteEvaluationOutput struct {
  3096. _ struct{} `type:"structure"`
  3097. // A user-supplied ID that uniquely identifies the Evaluation. This value should
  3098. // be identical to the value of the EvaluationId in the request.
  3099. EvaluationId *string `min:"1" type:"string"`
  3100. }
  3101. // String returns the string representation
  3102. func (s DeleteEvaluationOutput) String() string {
  3103. return awsutil.Prettify(s)
  3104. }
  3105. // GoString returns the string representation
  3106. func (s DeleteEvaluationOutput) GoString() string {
  3107. return s.String()
  3108. }
  3109. type DeleteMLModelInput struct {
  3110. _ struct{} `type:"structure"`
  3111. // A user-supplied ID that uniquely identifies the MLModel.
  3112. //
  3113. // MLModelId is a required field
  3114. MLModelId *string `min:"1" type:"string" required:"true"`
  3115. }
  3116. // String returns the string representation
  3117. func (s DeleteMLModelInput) String() string {
  3118. return awsutil.Prettify(s)
  3119. }
  3120. // GoString returns the string representation
  3121. func (s DeleteMLModelInput) GoString() string {
  3122. return s.String()
  3123. }
  3124. // Validate inspects the fields of the type to determine if they are valid.
  3125. func (s *DeleteMLModelInput) Validate() error {
  3126. invalidParams := request.ErrInvalidParams{Context: "DeleteMLModelInput"}
  3127. if s.MLModelId == nil {
  3128. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  3129. }
  3130. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  3131. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  3132. }
  3133. if invalidParams.Len() > 0 {
  3134. return invalidParams
  3135. }
  3136. return nil
  3137. }
  3138. // Represents the output of a DeleteMLModel operation.
  3139. //
  3140. // You can use the GetMLModel operation and check the value of the Status parameter
  3141. // to see whether an MLModel is marked as DELETED.
  3142. type DeleteMLModelOutput struct {
  3143. _ struct{} `type:"structure"`
  3144. // A user-supplied ID that uniquely identifies the MLModel. This value should
  3145. // be identical to the value of the MLModelID in the request.
  3146. MLModelId *string `min:"1" type:"string"`
  3147. }
  3148. // String returns the string representation
  3149. func (s DeleteMLModelOutput) String() string {
  3150. return awsutil.Prettify(s)
  3151. }
  3152. // GoString returns the string representation
  3153. func (s DeleteMLModelOutput) GoString() string {
  3154. return s.String()
  3155. }
  3156. type DeleteRealtimeEndpointInput struct {
  3157. _ struct{} `type:"structure"`
  3158. // The ID assigned to the MLModel during creation.
  3159. //
  3160. // MLModelId is a required field
  3161. MLModelId *string `min:"1" type:"string" required:"true"`
  3162. }
  3163. // String returns the string representation
  3164. func (s DeleteRealtimeEndpointInput) String() string {
  3165. return awsutil.Prettify(s)
  3166. }
  3167. // GoString returns the string representation
  3168. func (s DeleteRealtimeEndpointInput) GoString() string {
  3169. return s.String()
  3170. }
  3171. // Validate inspects the fields of the type to determine if they are valid.
  3172. func (s *DeleteRealtimeEndpointInput) Validate() error {
  3173. invalidParams := request.ErrInvalidParams{Context: "DeleteRealtimeEndpointInput"}
  3174. if s.MLModelId == nil {
  3175. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  3176. }
  3177. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  3178. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  3179. }
  3180. if invalidParams.Len() > 0 {
  3181. return invalidParams
  3182. }
  3183. return nil
  3184. }
  3185. // Represents the output of an DeleteRealtimeEndpoint operation.
  3186. //
  3187. // The result contains the MLModelId and the endpoint information for the MLModel.
  3188. type DeleteRealtimeEndpointOutput struct {
  3189. _ struct{} `type:"structure"`
  3190. // A user-supplied ID that uniquely identifies the MLModel. This value should
  3191. // be identical to the value of the MLModelId in the request.
  3192. MLModelId *string `min:"1" type:"string"`
  3193. // The endpoint information of the MLModel
  3194. RealtimeEndpointInfo *RealtimeEndpointInfo `type:"structure"`
  3195. }
  3196. // String returns the string representation
  3197. func (s DeleteRealtimeEndpointOutput) String() string {
  3198. return awsutil.Prettify(s)
  3199. }
  3200. // GoString returns the string representation
  3201. func (s DeleteRealtimeEndpointOutput) GoString() string {
  3202. return s.String()
  3203. }
  3204. type DeleteTagsInput struct {
  3205. _ struct{} `type:"structure"`
  3206. // The ID of the tagged ML object. For example, exampleModelId.
  3207. //
  3208. // ResourceId is a required field
  3209. ResourceId *string `min:"1" type:"string" required:"true"`
  3210. // The type of the tagged ML object.
  3211. //
  3212. // ResourceType is a required field
  3213. ResourceType *string `type:"string" required:"true" enum:"TaggableResourceType"`
  3214. // One or more tags to delete.
  3215. //
  3216. // TagKeys is a required field
  3217. TagKeys []*string `type:"list" required:"true"`
  3218. }
  3219. // String returns the string representation
  3220. func (s DeleteTagsInput) String() string {
  3221. return awsutil.Prettify(s)
  3222. }
  3223. // GoString returns the string representation
  3224. func (s DeleteTagsInput) GoString() string {
  3225. return s.String()
  3226. }
  3227. // Validate inspects the fields of the type to determine if they are valid.
  3228. func (s *DeleteTagsInput) Validate() error {
  3229. invalidParams := request.ErrInvalidParams{Context: "DeleteTagsInput"}
  3230. if s.ResourceId == nil {
  3231. invalidParams.Add(request.NewErrParamRequired("ResourceId"))
  3232. }
  3233. if s.ResourceId != nil && len(*s.ResourceId) < 1 {
  3234. invalidParams.Add(request.NewErrParamMinLen("ResourceId", 1))
  3235. }
  3236. if s.ResourceType == nil {
  3237. invalidParams.Add(request.NewErrParamRequired("ResourceType"))
  3238. }
  3239. if s.TagKeys == nil {
  3240. invalidParams.Add(request.NewErrParamRequired("TagKeys"))
  3241. }
  3242. if invalidParams.Len() > 0 {
  3243. return invalidParams
  3244. }
  3245. return nil
  3246. }
  3247. // Amazon ML returns the following elements.
  3248. type DeleteTagsOutput struct {
  3249. _ struct{} `type:"structure"`
  3250. // The ID of the ML object from which tags were deleted.
  3251. ResourceId *string `min:"1" type:"string"`
  3252. // The type of the ML object from which tags were deleted.
  3253. ResourceType *string `type:"string" enum:"TaggableResourceType"`
  3254. }
  3255. // String returns the string representation
  3256. func (s DeleteTagsOutput) String() string {
  3257. return awsutil.Prettify(s)
  3258. }
  3259. // GoString returns the string representation
  3260. func (s DeleteTagsOutput) GoString() string {
  3261. return s.String()
  3262. }
  3263. type DescribeBatchPredictionsInput struct {
  3264. _ struct{} `type:"structure"`
  3265. // The equal to operator. The BatchPrediction results will have FilterVariable
  3266. // values that exactly match the value specified with EQ.
  3267. EQ *string `type:"string"`
  3268. // Use one of the following variables to filter a list of BatchPrediction:
  3269. //
  3270. // * CreatedAt - Sets the search criteria to the BatchPrediction creation
  3271. // date.
  3272. // * Status - Sets the search criteria to the BatchPrediction status.
  3273. // * Name - Sets the search criteria to the contents of the BatchPredictionName.
  3274. //
  3275. // * IAMUser - Sets the search criteria to the user account that invoked
  3276. // the BatchPrediction creation.
  3277. // * MLModelId - Sets the search criteria to the MLModel used in the BatchPrediction.
  3278. //
  3279. // * DataSourceId - Sets the search criteria to the DataSource used in the
  3280. // BatchPrediction.
  3281. // * DataURI - Sets the search criteria to the data file(s) used in the BatchPrediction.
  3282. // The URL can identify either a file or an Amazon Simple Storage Solution
  3283. // (Amazon S3) bucket or directory.
  3284. FilterVariable *string `type:"string" enum:"BatchPredictionFilterVariable"`
  3285. // The greater than or equal to operator. The BatchPrediction results will have
  3286. // FilterVariable values that are greater than or equal to the value specified
  3287. // with GE.
  3288. GE *string `type:"string"`
  3289. // The greater than operator. The BatchPrediction results will have FilterVariable
  3290. // values that are greater than the value specified with GT.
  3291. GT *string `type:"string"`
  3292. // The less than or equal to operator. The BatchPrediction results will have
  3293. // FilterVariable values that are less than or equal to the value specified
  3294. // with LE.
  3295. LE *string `type:"string"`
  3296. // The less than operator. The BatchPrediction results will have FilterVariable
  3297. // values that are less than the value specified with LT.
  3298. LT *string `type:"string"`
  3299. // The number of pages of information to include in the result. The range of
  3300. // acceptable values is 1 through 100. The default value is 100.
  3301. Limit *int64 `min:"1" type:"integer"`
  3302. // The not equal to operator. The BatchPrediction results will have FilterVariable
  3303. // values not equal to the value specified with NE.
  3304. NE *string `type:"string"`
  3305. // An ID of the page in the paginated results.
  3306. NextToken *string `type:"string"`
  3307. // A string that is found at the beginning of a variable, such as Name or Id.
  3308. //
  3309. // For example, a Batch Prediction operation could have the Name2014-09-09-HolidayGiftMailer.
  3310. // To search for this BatchPrediction, select Name for the FilterVariable and
  3311. // any of the following strings for the Prefix:
  3312. //
  3313. // * 2014-09
  3314. //
  3315. // * 2014-09-09
  3316. //
  3317. // * 2014-09-09-Holiday
  3318. Prefix *string `type:"string"`
  3319. // A two-value parameter that determines the sequence of the resulting list
  3320. // of MLModels.
  3321. //
  3322. // * asc - Arranges the list in ascending order (A-Z, 0-9).
  3323. // * dsc - Arranges the list in descending order (Z-A, 9-0).
  3324. // Results are sorted by FilterVariable.
  3325. SortOrder *string `type:"string" enum:"SortOrder"`
  3326. }
  3327. // String returns the string representation
  3328. func (s DescribeBatchPredictionsInput) String() string {
  3329. return awsutil.Prettify(s)
  3330. }
  3331. // GoString returns the string representation
  3332. func (s DescribeBatchPredictionsInput) GoString() string {
  3333. return s.String()
  3334. }
  3335. // Validate inspects the fields of the type to determine if they are valid.
  3336. func (s *DescribeBatchPredictionsInput) Validate() error {
  3337. invalidParams := request.ErrInvalidParams{Context: "DescribeBatchPredictionsInput"}
  3338. if s.Limit != nil && *s.Limit < 1 {
  3339. invalidParams.Add(request.NewErrParamMinValue("Limit", 1))
  3340. }
  3341. if invalidParams.Len() > 0 {
  3342. return invalidParams
  3343. }
  3344. return nil
  3345. }
  3346. // Represents the output of a DescribeBatchPredictions operation. The content
  3347. // is essentially a list of BatchPredictions.
  3348. type DescribeBatchPredictionsOutput struct {
  3349. _ struct{} `type:"structure"`
  3350. // The ID of the next page in the paginated results that indicates at least
  3351. // one more page follows.
  3352. NextToken *string `type:"string"`
  3353. // A list of BatchPrediction objects that meet the search criteria.
  3354. Results []*BatchPrediction `type:"list"`
  3355. }
  3356. // String returns the string representation
  3357. func (s DescribeBatchPredictionsOutput) String() string {
  3358. return awsutil.Prettify(s)
  3359. }
  3360. // GoString returns the string representation
  3361. func (s DescribeBatchPredictionsOutput) GoString() string {
  3362. return s.String()
  3363. }
  3364. type DescribeDataSourcesInput struct {
  3365. _ struct{} `type:"structure"`
  3366. // The equal to operator. The DataSource results will have FilterVariable values
  3367. // that exactly match the value specified with EQ.
  3368. EQ *string `type:"string"`
  3369. // Use one of the following variables to filter a list of DataSource:
  3370. //
  3371. // * CreatedAt - Sets the search criteria to DataSource creation dates.
  3372. // * Status - Sets the search criteria to DataSource statuses.
  3373. // * Name - Sets the search criteria to the contents of DataSourceName.
  3374. // * DataUri - Sets the search criteria to the URI of data files used to
  3375. // create the DataSource. The URI can identify either a file or an Amazon
  3376. // Simple Storage Service (Amazon S3) bucket or directory.
  3377. // * IAMUser - Sets the search criteria to the user account that invoked
  3378. // the DataSource creation.
  3379. FilterVariable *string `type:"string" enum:"DataSourceFilterVariable"`
  3380. // The greater than or equal to operator. The DataSource results will have FilterVariable
  3381. // values that are greater than or equal to the value specified with GE.
  3382. GE *string `type:"string"`
  3383. // The greater than operator. The DataSource results will have FilterVariable
  3384. // values that are greater than the value specified with GT.
  3385. GT *string `type:"string"`
  3386. // The less than or equal to operator. The DataSource results will have FilterVariable
  3387. // values that are less than or equal to the value specified with LE.
  3388. LE *string `type:"string"`
  3389. // The less than operator. The DataSource results will have FilterVariable values
  3390. // that are less than the value specified with LT.
  3391. LT *string `type:"string"`
  3392. // The maximum number of DataSource to include in the result.
  3393. Limit *int64 `min:"1" type:"integer"`
  3394. // The not equal to operator. The DataSource results will have FilterVariable
  3395. // values not equal to the value specified with NE.
  3396. NE *string `type:"string"`
  3397. // The ID of the page in the paginated results.
  3398. NextToken *string `type:"string"`
  3399. // A string that is found at the beginning of a variable, such as Name or Id.
  3400. //
  3401. // For example, a DataSource could have the Name2014-09-09-HolidayGiftMailer.
  3402. // To search for this DataSource, select Name for the FilterVariable and any
  3403. // of the following strings for the Prefix:
  3404. //
  3405. // * 2014-09
  3406. //
  3407. // * 2014-09-09
  3408. //
  3409. // * 2014-09-09-Holiday
  3410. Prefix *string `type:"string"`
  3411. // A two-value parameter that determines the sequence of the resulting list
  3412. // of DataSource.
  3413. //
  3414. // * asc - Arranges the list in ascending order (A-Z, 0-9).
  3415. // * dsc - Arranges the list in descending order (Z-A, 9-0).
  3416. // Results are sorted by FilterVariable.
  3417. SortOrder *string `type:"string" enum:"SortOrder"`
  3418. }
  3419. // String returns the string representation
  3420. func (s DescribeDataSourcesInput) String() string {
  3421. return awsutil.Prettify(s)
  3422. }
  3423. // GoString returns the string representation
  3424. func (s DescribeDataSourcesInput) GoString() string {
  3425. return s.String()
  3426. }
  3427. // Validate inspects the fields of the type to determine if they are valid.
  3428. func (s *DescribeDataSourcesInput) Validate() error {
  3429. invalidParams := request.ErrInvalidParams{Context: "DescribeDataSourcesInput"}
  3430. if s.Limit != nil && *s.Limit < 1 {
  3431. invalidParams.Add(request.NewErrParamMinValue("Limit", 1))
  3432. }
  3433. if invalidParams.Len() > 0 {
  3434. return invalidParams
  3435. }
  3436. return nil
  3437. }
  3438. // Represents the query results from a DescribeDataSources operation. The content
  3439. // is essentially a list of DataSource.
  3440. type DescribeDataSourcesOutput struct {
  3441. _ struct{} `type:"structure"`
  3442. // An ID of the next page in the paginated results that indicates at least one
  3443. // more page follows.
  3444. NextToken *string `type:"string"`
  3445. // A list of DataSource that meet the search criteria.
  3446. Results []*DataSource `type:"list"`
  3447. }
  3448. // String returns the string representation
  3449. func (s DescribeDataSourcesOutput) String() string {
  3450. return awsutil.Prettify(s)
  3451. }
  3452. // GoString returns the string representation
  3453. func (s DescribeDataSourcesOutput) GoString() string {
  3454. return s.String()
  3455. }
  3456. type DescribeEvaluationsInput struct {
  3457. _ struct{} `type:"structure"`
  3458. // The equal to operator. The Evaluation results will have FilterVariable values
  3459. // that exactly match the value specified with EQ.
  3460. EQ *string `type:"string"`
  3461. // Use one of the following variable to filter a list of Evaluation objects:
  3462. //
  3463. // * CreatedAt - Sets the search criteria to the Evaluation creation date.
  3464. //
  3465. // * Status - Sets the search criteria to the Evaluation status.
  3466. // * Name - Sets the search criteria to the contents of EvaluationName.
  3467. // * IAMUser - Sets the search criteria to the user account that invoked
  3468. // an Evaluation.
  3469. // * MLModelId - Sets the search criteria to the MLModel that was evaluated.
  3470. //
  3471. // * DataSourceId - Sets the search criteria to the DataSource used in Evaluation.
  3472. //
  3473. // * DataUri - Sets the search criteria to the data file(s) used in Evaluation.
  3474. // The URL can identify either a file or an Amazon Simple Storage Solution
  3475. // (Amazon S3) bucket or directory.
  3476. FilterVariable *string `type:"string" enum:"EvaluationFilterVariable"`
  3477. // The greater than or equal to operator. The Evaluation results will have FilterVariable
  3478. // values that are greater than or equal to the value specified with GE.
  3479. GE *string `type:"string"`
  3480. // The greater than operator. The Evaluation results will have FilterVariable
  3481. // values that are greater than the value specified with GT.
  3482. GT *string `type:"string"`
  3483. // The less than or equal to operator. The Evaluation results will have FilterVariable
  3484. // values that are less than or equal to the value specified with LE.
  3485. LE *string `type:"string"`
  3486. // The less than operator. The Evaluation results will have FilterVariable values
  3487. // that are less than the value specified with LT.
  3488. LT *string `type:"string"`
  3489. // The maximum number of Evaluation to include in the result.
  3490. Limit *int64 `min:"1" type:"integer"`
  3491. // The not equal to operator. The Evaluation results will have FilterVariable
  3492. // values not equal to the value specified with NE.
  3493. NE *string `type:"string"`
  3494. // The ID of the page in the paginated results.
  3495. NextToken *string `type:"string"`
  3496. // A string that is found at the beginning of a variable, such as Name or Id.
  3497. //
  3498. // For example, an Evaluation could have the Name2014-09-09-HolidayGiftMailer.
  3499. // To search for this Evaluation, select Name for the FilterVariable and any
  3500. // of the following strings for the Prefix:
  3501. //
  3502. // * 2014-09
  3503. //
  3504. // * 2014-09-09
  3505. //
  3506. // * 2014-09-09-Holiday
  3507. Prefix *string `type:"string"`
  3508. // A two-value parameter that determines the sequence of the resulting list
  3509. // of Evaluation.
  3510. //
  3511. // * asc - Arranges the list in ascending order (A-Z, 0-9).
  3512. // * dsc - Arranges the list in descending order (Z-A, 9-0).
  3513. // Results are sorted by FilterVariable.
  3514. SortOrder *string `type:"string" enum:"SortOrder"`
  3515. }
  3516. // String returns the string representation
  3517. func (s DescribeEvaluationsInput) String() string {
  3518. return awsutil.Prettify(s)
  3519. }
  3520. // GoString returns the string representation
  3521. func (s DescribeEvaluationsInput) GoString() string {
  3522. return s.String()
  3523. }
  3524. // Validate inspects the fields of the type to determine if they are valid.
  3525. func (s *DescribeEvaluationsInput) Validate() error {
  3526. invalidParams := request.ErrInvalidParams{Context: "DescribeEvaluationsInput"}
  3527. if s.Limit != nil && *s.Limit < 1 {
  3528. invalidParams.Add(request.NewErrParamMinValue("Limit", 1))
  3529. }
  3530. if invalidParams.Len() > 0 {
  3531. return invalidParams
  3532. }
  3533. return nil
  3534. }
  3535. // Represents the query results from a DescribeEvaluations operation. The content
  3536. // is essentially a list of Evaluation.
  3537. type DescribeEvaluationsOutput struct {
  3538. _ struct{} `type:"structure"`
  3539. // The ID of the next page in the paginated results that indicates at least
  3540. // one more page follows.
  3541. NextToken *string `type:"string"`
  3542. // A list of Evaluation that meet the search criteria.
  3543. Results []*Evaluation `type:"list"`
  3544. }
  3545. // String returns the string representation
  3546. func (s DescribeEvaluationsOutput) String() string {
  3547. return awsutil.Prettify(s)
  3548. }
  3549. // GoString returns the string representation
  3550. func (s DescribeEvaluationsOutput) GoString() string {
  3551. return s.String()
  3552. }
  3553. type DescribeMLModelsInput struct {
  3554. _ struct{} `type:"structure"`
  3555. // The equal to operator. The MLModel results will have FilterVariable values
  3556. // that exactly match the value specified with EQ.
  3557. EQ *string `type:"string"`
  3558. // Use one of the following variables to filter a list of MLModel:
  3559. //
  3560. // * CreatedAt - Sets the search criteria to MLModel creation date.
  3561. // * Status - Sets the search criteria to MLModel status.
  3562. // * Name - Sets the search criteria to the contents of MLModelName.
  3563. // * IAMUser - Sets the search criteria to the user account that invoked
  3564. // the MLModel creation.
  3565. // * TrainingDataSourceId - Sets the search criteria to the DataSource used
  3566. // to train one or more MLModel.
  3567. // * RealtimeEndpointStatus - Sets the search criteria to the MLModel real-time
  3568. // endpoint status.
  3569. // * MLModelType - Sets the search criteria to MLModel type: binary, regression,
  3570. // or multi-class.
  3571. // * Algorithm - Sets the search criteria to the algorithm that the MLModel
  3572. // uses.
  3573. // * TrainingDataURI - Sets the search criteria to the data file(s) used
  3574. // in training a MLModel. The URL can identify either a file or an Amazon
  3575. // Simple Storage Service (Amazon S3) bucket or directory.
  3576. FilterVariable *string `type:"string" enum:"MLModelFilterVariable"`
  3577. // The greater than or equal to operator. The MLModel results will have FilterVariable
  3578. // values that are greater than or equal to the value specified with GE.
  3579. GE *string `type:"string"`
  3580. // The greater than operator. The MLModel results will have FilterVariable values
  3581. // that are greater than the value specified with GT.
  3582. GT *string `type:"string"`
  3583. // The less than or equal to operator. The MLModel results will have FilterVariable
  3584. // values that are less than or equal to the value specified with LE.
  3585. LE *string `type:"string"`
  3586. // The less than operator. The MLModel results will have FilterVariable values
  3587. // that are less than the value specified with LT.
  3588. LT *string `type:"string"`
  3589. // The number of pages of information to include in the result. The range of
  3590. // acceptable values is 1 through 100. The default value is 100.
  3591. Limit *int64 `min:"1" type:"integer"`
  3592. // The not equal to operator. The MLModel results will have FilterVariable values
  3593. // not equal to the value specified with NE.
  3594. NE *string `type:"string"`
  3595. // The ID of the page in the paginated results.
  3596. NextToken *string `type:"string"`
  3597. // A string that is found at the beginning of a variable, such as Name or Id.
  3598. //
  3599. // For example, an MLModel could have the Name2014-09-09-HolidayGiftMailer.
  3600. // To search for this MLModel, select Name for the FilterVariable and any of
  3601. // the following strings for the Prefix:
  3602. //
  3603. // * 2014-09
  3604. //
  3605. // * 2014-09-09
  3606. //
  3607. // * 2014-09-09-Holiday
  3608. Prefix *string `type:"string"`
  3609. // A two-value parameter that determines the sequence of the resulting list
  3610. // of MLModel.
  3611. //
  3612. // * asc - Arranges the list in ascending order (A-Z, 0-9).
  3613. // * dsc - Arranges the list in descending order (Z-A, 9-0).
  3614. // Results are sorted by FilterVariable.
  3615. SortOrder *string `type:"string" enum:"SortOrder"`
  3616. }
  3617. // String returns the string representation
  3618. func (s DescribeMLModelsInput) String() string {
  3619. return awsutil.Prettify(s)
  3620. }
  3621. // GoString returns the string representation
  3622. func (s DescribeMLModelsInput) GoString() string {
  3623. return s.String()
  3624. }
  3625. // Validate inspects the fields of the type to determine if they are valid.
  3626. func (s *DescribeMLModelsInput) Validate() error {
  3627. invalidParams := request.ErrInvalidParams{Context: "DescribeMLModelsInput"}
  3628. if s.Limit != nil && *s.Limit < 1 {
  3629. invalidParams.Add(request.NewErrParamMinValue("Limit", 1))
  3630. }
  3631. if invalidParams.Len() > 0 {
  3632. return invalidParams
  3633. }
  3634. return nil
  3635. }
  3636. // Represents the output of a DescribeMLModels operation. The content is essentially
  3637. // a list of MLModel.
  3638. type DescribeMLModelsOutput struct {
  3639. _ struct{} `type:"structure"`
  3640. // The ID of the next page in the paginated results that indicates at least
  3641. // one more page follows.
  3642. NextToken *string `type:"string"`
  3643. // A list of MLModel that meet the search criteria.
  3644. Results []*MLModel `type:"list"`
  3645. }
  3646. // String returns the string representation
  3647. func (s DescribeMLModelsOutput) String() string {
  3648. return awsutil.Prettify(s)
  3649. }
  3650. // GoString returns the string representation
  3651. func (s DescribeMLModelsOutput) GoString() string {
  3652. return s.String()
  3653. }
  3654. type DescribeTagsInput struct {
  3655. _ struct{} `type:"structure"`
  3656. // The ID of the ML object. For example, exampleModelId.
  3657. //
  3658. // ResourceId is a required field
  3659. ResourceId *string `min:"1" type:"string" required:"true"`
  3660. // The type of the ML object.
  3661. //
  3662. // ResourceType is a required field
  3663. ResourceType *string `type:"string" required:"true" enum:"TaggableResourceType"`
  3664. }
  3665. // String returns the string representation
  3666. func (s DescribeTagsInput) String() string {
  3667. return awsutil.Prettify(s)
  3668. }
  3669. // GoString returns the string representation
  3670. func (s DescribeTagsInput) GoString() string {
  3671. return s.String()
  3672. }
  3673. // Validate inspects the fields of the type to determine if they are valid.
  3674. func (s *DescribeTagsInput) Validate() error {
  3675. invalidParams := request.ErrInvalidParams{Context: "DescribeTagsInput"}
  3676. if s.ResourceId == nil {
  3677. invalidParams.Add(request.NewErrParamRequired("ResourceId"))
  3678. }
  3679. if s.ResourceId != nil && len(*s.ResourceId) < 1 {
  3680. invalidParams.Add(request.NewErrParamMinLen("ResourceId", 1))
  3681. }
  3682. if s.ResourceType == nil {
  3683. invalidParams.Add(request.NewErrParamRequired("ResourceType"))
  3684. }
  3685. if invalidParams.Len() > 0 {
  3686. return invalidParams
  3687. }
  3688. return nil
  3689. }
  3690. // Amazon ML returns the following elements.
  3691. type DescribeTagsOutput struct {
  3692. _ struct{} `type:"structure"`
  3693. // The ID of the tagged ML object.
  3694. ResourceId *string `min:"1" type:"string"`
  3695. // The type of the tagged ML object.
  3696. ResourceType *string `type:"string" enum:"TaggableResourceType"`
  3697. // A list of tags associated with the ML object.
  3698. Tags []*Tag `type:"list"`
  3699. }
  3700. // String returns the string representation
  3701. func (s DescribeTagsOutput) String() string {
  3702. return awsutil.Prettify(s)
  3703. }
  3704. // GoString returns the string representation
  3705. func (s DescribeTagsOutput) GoString() string {
  3706. return s.String()
  3707. }
  3708. // Represents the output of GetEvaluation operation.
  3709. //
  3710. // The content consists of the detailed metadata and data file information and
  3711. // the current status of the Evaluation.
  3712. type Evaluation struct {
  3713. _ struct{} `type:"structure"`
  3714. // Long integer type that is a 64-bit signed number.
  3715. ComputeTime *int64 `type:"long"`
  3716. // The time that the Evaluation was created. The time is expressed in epoch
  3717. // time.
  3718. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3719. // The AWS user account that invoked the evaluation. The account type can be
  3720. // either an AWS root account or an AWS Identity and Access Management (IAM)
  3721. // user account.
  3722. CreatedByIamUser *string `type:"string"`
  3723. // The ID of the DataSource that is used to evaluate the MLModel.
  3724. EvaluationDataSourceId *string `min:"1" type:"string"`
  3725. // The ID that is assigned to the Evaluation at creation.
  3726. EvaluationId *string `min:"1" type:"string"`
  3727. // A timestamp represented in epoch time.
  3728. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3729. // The location and name of the data in Amazon Simple Storage Server (Amazon
  3730. // S3) that is used in the evaluation.
  3731. InputDataLocationS3 *string `type:"string"`
  3732. // The time of the most recent edit to the Evaluation. The time is expressed
  3733. // in epoch time.
  3734. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3735. // The ID of the MLModel that is the focus of the evaluation.
  3736. MLModelId *string `min:"1" type:"string"`
  3737. // A description of the most recent details about evaluating the MLModel.
  3738. Message *string `type:"string"`
  3739. // A user-supplied name or description of the Evaluation.
  3740. Name *string `type:"string"`
  3741. // Measurements of how well the MLModel performed, using observations referenced
  3742. // by the DataSource. One of the following metrics is returned, based on the
  3743. // type of the MLModel:
  3744. //
  3745. // * BinaryAUC: A binary MLModel uses the Area Under the Curve (AUC) technique
  3746. // to measure performance.
  3747. //
  3748. // * RegressionRMSE: A regression MLModel uses the Root Mean Square Error
  3749. // (RMSE) technique to measure performance. RMSE measures the difference
  3750. // between predicted and actual values for a single variable.
  3751. //
  3752. // * MulticlassAvgFScore: A multiclass MLModel uses the F1 score technique
  3753. // to measure performance.
  3754. //
  3755. // For more information about performance metrics, please see the Amazon Machine
  3756. // Learning Developer Guide (http://docs.aws.amazon.com/machine-learning/latest/dg).
  3757. PerformanceMetrics *PerformanceMetrics `type:"structure"`
  3758. // A timestamp represented in epoch time.
  3759. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3760. // The status of the evaluation. This element can have one of the following
  3761. // values:
  3762. //
  3763. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  3764. // evaluate an MLModel.
  3765. // * INPROGRESS - The evaluation is underway.
  3766. // * FAILED - The request to evaluate an MLModel did not run to completion.
  3767. // It is not usable.
  3768. // * COMPLETED - The evaluation process completed successfully.
  3769. // * DELETED - The Evaluation is marked as deleted. It is not usable.
  3770. Status *string `type:"string" enum:"EntityStatus"`
  3771. }
  3772. // String returns the string representation
  3773. func (s Evaluation) String() string {
  3774. return awsutil.Prettify(s)
  3775. }
  3776. // GoString returns the string representation
  3777. func (s Evaluation) GoString() string {
  3778. return s.String()
  3779. }
  3780. type GetBatchPredictionInput struct {
  3781. _ struct{} `type:"structure"`
  3782. // An ID assigned to the BatchPrediction at creation.
  3783. //
  3784. // BatchPredictionId is a required field
  3785. BatchPredictionId *string `min:"1" type:"string" required:"true"`
  3786. }
  3787. // String returns the string representation
  3788. func (s GetBatchPredictionInput) String() string {
  3789. return awsutil.Prettify(s)
  3790. }
  3791. // GoString returns the string representation
  3792. func (s GetBatchPredictionInput) GoString() string {
  3793. return s.String()
  3794. }
  3795. // Validate inspects the fields of the type to determine if they are valid.
  3796. func (s *GetBatchPredictionInput) Validate() error {
  3797. invalidParams := request.ErrInvalidParams{Context: "GetBatchPredictionInput"}
  3798. if s.BatchPredictionId == nil {
  3799. invalidParams.Add(request.NewErrParamRequired("BatchPredictionId"))
  3800. }
  3801. if s.BatchPredictionId != nil && len(*s.BatchPredictionId) < 1 {
  3802. invalidParams.Add(request.NewErrParamMinLen("BatchPredictionId", 1))
  3803. }
  3804. if invalidParams.Len() > 0 {
  3805. return invalidParams
  3806. }
  3807. return nil
  3808. }
  3809. // Represents the output of a GetBatchPrediction operation and describes a BatchPrediction.
  3810. type GetBatchPredictionOutput struct {
  3811. _ struct{} `type:"structure"`
  3812. // The ID of the DataSource that was used to create the BatchPrediction.
  3813. BatchPredictionDataSourceId *string `min:"1" type:"string"`
  3814. // An ID assigned to the BatchPrediction at creation. This value should be identical
  3815. // to the value of the BatchPredictionID in the request.
  3816. BatchPredictionId *string `min:"1" type:"string"`
  3817. // The approximate CPU time in milliseconds that Amazon Machine Learning spent
  3818. // processing the BatchPrediction, normalized and scaled on computation resources.
  3819. // ComputeTime is only available if the BatchPrediction is in the COMPLETED
  3820. // state.
  3821. ComputeTime *int64 `type:"long"`
  3822. // The time when the BatchPrediction was created. The time is expressed in epoch
  3823. // time.
  3824. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3825. // The AWS user account that invoked the BatchPrediction. The account type can
  3826. // be either an AWS root account or an AWS Identity and Access Management (IAM)
  3827. // user account.
  3828. CreatedByIamUser *string `type:"string"`
  3829. // The epoch time when Amazon Machine Learning marked the BatchPrediction as
  3830. // COMPLETED or FAILED. FinishedAt is only available when the BatchPrediction
  3831. // is in the COMPLETED or FAILED state.
  3832. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3833. // The location of the data file or directory in Amazon Simple Storage Service
  3834. // (Amazon S3).
  3835. InputDataLocationS3 *string `type:"string"`
  3836. // The number of invalid records that Amazon Machine Learning saw while processing
  3837. // the BatchPrediction.
  3838. InvalidRecordCount *int64 `type:"long"`
  3839. // The time of the most recent edit to BatchPrediction. The time is expressed
  3840. // in epoch time.
  3841. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3842. // A link to the file that contains logs of the CreateBatchPrediction operation.
  3843. LogUri *string `type:"string"`
  3844. // The ID of the MLModel that generated predictions for the BatchPrediction
  3845. // request.
  3846. MLModelId *string `min:"1" type:"string"`
  3847. // A description of the most recent details about processing the batch prediction
  3848. // request.
  3849. Message *string `type:"string"`
  3850. // A user-supplied name or description of the BatchPrediction.
  3851. Name *string `type:"string"`
  3852. // The location of an Amazon S3 bucket or directory to receive the operation
  3853. // results.
  3854. OutputUri *string `type:"string"`
  3855. // The epoch time when Amazon Machine Learning marked the BatchPrediction as
  3856. // INPROGRESS. StartedAt isn't available if the BatchPrediction is in the PENDING
  3857. // state.
  3858. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3859. // The status of the BatchPrediction, which can be one of the following values:
  3860. //
  3861. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  3862. // generate batch predictions.
  3863. // * INPROGRESS - The batch predictions are in progress.
  3864. // * FAILED - The request to perform a batch prediction did not run to completion.
  3865. // It is not usable.
  3866. // * COMPLETED - The batch prediction process completed successfully.
  3867. // * DELETED - The BatchPrediction is marked as deleted. It is not usable.
  3868. Status *string `type:"string" enum:"EntityStatus"`
  3869. // The number of total records that Amazon Machine Learning saw while processing
  3870. // the BatchPrediction.
  3871. TotalRecordCount *int64 `type:"long"`
  3872. }
  3873. // String returns the string representation
  3874. func (s GetBatchPredictionOutput) String() string {
  3875. return awsutil.Prettify(s)
  3876. }
  3877. // GoString returns the string representation
  3878. func (s GetBatchPredictionOutput) GoString() string {
  3879. return s.String()
  3880. }
  3881. type GetDataSourceInput struct {
  3882. _ struct{} `type:"structure"`
  3883. // The ID assigned to the DataSource at creation.
  3884. //
  3885. // DataSourceId is a required field
  3886. DataSourceId *string `min:"1" type:"string" required:"true"`
  3887. // Specifies whether the GetDataSource operation should return DataSourceSchema.
  3888. //
  3889. // If true, DataSourceSchema is returned.
  3890. //
  3891. // If false, DataSourceSchema is not returned.
  3892. Verbose *bool `type:"boolean"`
  3893. }
  3894. // String returns the string representation
  3895. func (s GetDataSourceInput) String() string {
  3896. return awsutil.Prettify(s)
  3897. }
  3898. // GoString returns the string representation
  3899. func (s GetDataSourceInput) GoString() string {
  3900. return s.String()
  3901. }
  3902. // Validate inspects the fields of the type to determine if they are valid.
  3903. func (s *GetDataSourceInput) Validate() error {
  3904. invalidParams := request.ErrInvalidParams{Context: "GetDataSourceInput"}
  3905. if s.DataSourceId == nil {
  3906. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  3907. }
  3908. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  3909. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  3910. }
  3911. if invalidParams.Len() > 0 {
  3912. return invalidParams
  3913. }
  3914. return nil
  3915. }
  3916. // Represents the output of a GetDataSource operation and describes a DataSource.
  3917. type GetDataSourceOutput struct {
  3918. _ struct{} `type:"structure"`
  3919. // The parameter is true if statistics need to be generated from the observation
  3920. // data.
  3921. ComputeStatistics *bool `type:"boolean"`
  3922. // The approximate CPU time in milliseconds that Amazon Machine Learning spent
  3923. // processing the DataSource, normalized and scaled on computation resources.
  3924. // ComputeTime is only available if the DataSource is in the COMPLETED state
  3925. // and the ComputeStatistics is set to true.
  3926. ComputeTime *int64 `type:"long"`
  3927. // The time that the DataSource was created. The time is expressed in epoch
  3928. // time.
  3929. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3930. // The AWS user account from which the DataSource was created. The account type
  3931. // can be either an AWS root account or an AWS Identity and Access Management
  3932. // (IAM) user account.
  3933. CreatedByIamUser *string `type:"string"`
  3934. // The location of the data file or directory in Amazon Simple Storage Service
  3935. // (Amazon S3).
  3936. DataLocationS3 *string `type:"string"`
  3937. // A JSON string that represents the splitting and rearrangement requirement
  3938. // used when this DataSource was created.
  3939. DataRearrangement *string `type:"string"`
  3940. // The total size of observations in the data files.
  3941. DataSizeInBytes *int64 `type:"long"`
  3942. // The ID assigned to the DataSource at creation. This value should be identical
  3943. // to the value of the DataSourceId in the request.
  3944. DataSourceId *string `min:"1" type:"string"`
  3945. // The schema used by all of the data files of this DataSource.
  3946. //
  3947. // NoteThis parameter is provided as part of the verbose format.
  3948. DataSourceSchema *string `type:"string"`
  3949. // The epoch time when Amazon Machine Learning marked the DataSource as COMPLETED
  3950. // or FAILED. FinishedAt is only available when the DataSource is in the COMPLETED
  3951. // or FAILED state.
  3952. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3953. // The time of the most recent edit to the DataSource. The time is expressed
  3954. // in epoch time.
  3955. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3956. // A link to the file containing logs of CreateDataSourceFrom* operations.
  3957. LogUri *string `type:"string"`
  3958. // The user-supplied description of the most recent details about creating the
  3959. // DataSource.
  3960. Message *string `type:"string"`
  3961. // A user-supplied name or description of the DataSource.
  3962. Name *string `type:"string"`
  3963. // The number of data files referenced by the DataSource.
  3964. NumberOfFiles *int64 `type:"long"`
  3965. // The datasource details that are specific to Amazon RDS.
  3966. RDSMetadata *RDSMetadata `type:"structure"`
  3967. // Describes the DataSource details specific to Amazon Redshift.
  3968. RedshiftMetadata *RedshiftMetadata `type:"structure"`
  3969. // The Amazon Resource Name (ARN) of an AWS IAM Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts),
  3970. // such as the following: arn:aws:iam::account:role/rolename.
  3971. RoleARN *string `min:"1" type:"string"`
  3972. // The epoch time when Amazon Machine Learning marked the DataSource as INPROGRESS.
  3973. // StartedAt isn't available if the DataSource is in the PENDING state.
  3974. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  3975. // The current status of the DataSource. This element can have one of the following
  3976. // values:
  3977. //
  3978. // * PENDING - Amazon ML submitted a request to create a DataSource.
  3979. // * INPROGRESS - The creation process is underway.
  3980. // * FAILED - The request to create a DataSource did not run to completion.
  3981. // It is not usable.
  3982. // * COMPLETED - The creation process completed successfully.
  3983. // * DELETED - The DataSource is marked as deleted. It is not usable.
  3984. Status *string `type:"string" enum:"EntityStatus"`
  3985. }
  3986. // String returns the string representation
  3987. func (s GetDataSourceOutput) String() string {
  3988. return awsutil.Prettify(s)
  3989. }
  3990. // GoString returns the string representation
  3991. func (s GetDataSourceOutput) GoString() string {
  3992. return s.String()
  3993. }
  3994. type GetEvaluationInput struct {
  3995. _ struct{} `type:"structure"`
  3996. // The ID of the Evaluation to retrieve. The evaluation of each MLModel is recorded
  3997. // and cataloged. The ID provides the means to access the information.
  3998. //
  3999. // EvaluationId is a required field
  4000. EvaluationId *string `min:"1" type:"string" required:"true"`
  4001. }
  4002. // String returns the string representation
  4003. func (s GetEvaluationInput) String() string {
  4004. return awsutil.Prettify(s)
  4005. }
  4006. // GoString returns the string representation
  4007. func (s GetEvaluationInput) GoString() string {
  4008. return s.String()
  4009. }
  4010. // Validate inspects the fields of the type to determine if they are valid.
  4011. func (s *GetEvaluationInput) Validate() error {
  4012. invalidParams := request.ErrInvalidParams{Context: "GetEvaluationInput"}
  4013. if s.EvaluationId == nil {
  4014. invalidParams.Add(request.NewErrParamRequired("EvaluationId"))
  4015. }
  4016. if s.EvaluationId != nil && len(*s.EvaluationId) < 1 {
  4017. invalidParams.Add(request.NewErrParamMinLen("EvaluationId", 1))
  4018. }
  4019. if invalidParams.Len() > 0 {
  4020. return invalidParams
  4021. }
  4022. return nil
  4023. }
  4024. // Represents the output of a GetEvaluation operation and describes an Evaluation.
  4025. type GetEvaluationOutput struct {
  4026. _ struct{} `type:"structure"`
  4027. // The approximate CPU time in milliseconds that Amazon Machine Learning spent
  4028. // processing the Evaluation, normalized and scaled on computation resources.
  4029. // ComputeTime is only available if the Evaluation is in the COMPLETED state.
  4030. ComputeTime *int64 `type:"long"`
  4031. // The time that the Evaluation was created. The time is expressed in epoch
  4032. // time.
  4033. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4034. // The AWS user account that invoked the evaluation. The account type can be
  4035. // either an AWS root account or an AWS Identity and Access Management (IAM)
  4036. // user account.
  4037. CreatedByIamUser *string `type:"string"`
  4038. // The DataSource used for this evaluation.
  4039. EvaluationDataSourceId *string `min:"1" type:"string"`
  4040. // The evaluation ID which is same as the EvaluationId in the request.
  4041. EvaluationId *string `min:"1" type:"string"`
  4042. // The epoch time when Amazon Machine Learning marked the Evaluation as COMPLETED
  4043. // or FAILED. FinishedAt is only available when the Evaluation is in the COMPLETED
  4044. // or FAILED state.
  4045. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4046. // The location of the data file or directory in Amazon Simple Storage Service
  4047. // (Amazon S3).
  4048. InputDataLocationS3 *string `type:"string"`
  4049. // The time of the most recent edit to the Evaluation. The time is expressed
  4050. // in epoch time.
  4051. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4052. // A link to the file that contains logs of the CreateEvaluation operation.
  4053. LogUri *string `type:"string"`
  4054. // The ID of the MLModel that was the focus of the evaluation.
  4055. MLModelId *string `min:"1" type:"string"`
  4056. // A description of the most recent details about evaluating the MLModel.
  4057. Message *string `type:"string"`
  4058. // A user-supplied name or description of the Evaluation.
  4059. Name *string `type:"string"`
  4060. // Measurements of how well the MLModel performed using observations referenced
  4061. // by the DataSource. One of the following metric is returned based on the type
  4062. // of the MLModel:
  4063. //
  4064. // * BinaryAUC: A binary MLModel uses the Area Under the Curve (AUC) technique
  4065. // to measure performance.
  4066. //
  4067. // * RegressionRMSE: A regression MLModel uses the Root Mean Square Error
  4068. // (RMSE) technique to measure performance. RMSE measures the difference
  4069. // between predicted and actual values for a single variable.
  4070. //
  4071. // * MulticlassAvgFScore: A multiclass MLModel uses the F1 score technique
  4072. // to measure performance.
  4073. //
  4074. // For more information about performance metrics, please see the Amazon Machine
  4075. // Learning Developer Guide (http://docs.aws.amazon.com/machine-learning/latest/dg).
  4076. PerformanceMetrics *PerformanceMetrics `type:"structure"`
  4077. // The epoch time when Amazon Machine Learning marked the Evaluation as INPROGRESS.
  4078. // StartedAt isn't available if the Evaluation is in the PENDING state.
  4079. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4080. // The status of the evaluation. This element can have one of the following
  4081. // values:
  4082. //
  4083. // * PENDING - Amazon Machine Language (Amazon ML) submitted a request to
  4084. // evaluate an MLModel.
  4085. // * INPROGRESS - The evaluation is underway.
  4086. // * FAILED - The request to evaluate an MLModel did not run to completion.
  4087. // It is not usable.
  4088. // * COMPLETED - The evaluation process completed successfully.
  4089. // * DELETED - The Evaluation is marked as deleted. It is not usable.
  4090. Status *string `type:"string" enum:"EntityStatus"`
  4091. }
  4092. // String returns the string representation
  4093. func (s GetEvaluationOutput) String() string {
  4094. return awsutil.Prettify(s)
  4095. }
  4096. // GoString returns the string representation
  4097. func (s GetEvaluationOutput) GoString() string {
  4098. return s.String()
  4099. }
  4100. type GetMLModelInput struct {
  4101. _ struct{} `type:"structure"`
  4102. // The ID assigned to the MLModel at creation.
  4103. //
  4104. // MLModelId is a required field
  4105. MLModelId *string `min:"1" type:"string" required:"true"`
  4106. // Specifies whether the GetMLModel operation should return Recipe.
  4107. //
  4108. // If true, Recipe is returned.
  4109. //
  4110. // If false, Recipe is not returned.
  4111. Verbose *bool `type:"boolean"`
  4112. }
  4113. // String returns the string representation
  4114. func (s GetMLModelInput) String() string {
  4115. return awsutil.Prettify(s)
  4116. }
  4117. // GoString returns the string representation
  4118. func (s GetMLModelInput) GoString() string {
  4119. return s.String()
  4120. }
  4121. // Validate inspects the fields of the type to determine if they are valid.
  4122. func (s *GetMLModelInput) Validate() error {
  4123. invalidParams := request.ErrInvalidParams{Context: "GetMLModelInput"}
  4124. if s.MLModelId == nil {
  4125. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  4126. }
  4127. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  4128. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  4129. }
  4130. if invalidParams.Len() > 0 {
  4131. return invalidParams
  4132. }
  4133. return nil
  4134. }
  4135. // Represents the output of a GetMLModel operation, and provides detailed information
  4136. // about a MLModel.
  4137. type GetMLModelOutput struct {
  4138. _ struct{} `type:"structure"`
  4139. // The approximate CPU time in milliseconds that Amazon Machine Learning spent
  4140. // processing the MLModel, normalized and scaled on computation resources. ComputeTime
  4141. // is only available if the MLModel is in the COMPLETED state.
  4142. ComputeTime *int64 `type:"long"`
  4143. // The time that the MLModel was created. The time is expressed in epoch time.
  4144. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4145. // The AWS user account from which the MLModel was created. The account type
  4146. // can be either an AWS root account or an AWS Identity and Access Management
  4147. // (IAM) user account.
  4148. CreatedByIamUser *string `type:"string"`
  4149. // The current endpoint of the MLModel
  4150. EndpointInfo *RealtimeEndpointInfo `type:"structure"`
  4151. // The epoch time when Amazon Machine Learning marked the MLModel as COMPLETED
  4152. // or FAILED. FinishedAt is only available when the MLModel is in the COMPLETED
  4153. // or FAILED state.
  4154. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4155. // The location of the data file or directory in Amazon Simple Storage Service
  4156. // (Amazon S3).
  4157. InputDataLocationS3 *string `type:"string"`
  4158. // The time of the most recent edit to the MLModel. The time is expressed in
  4159. // epoch time.
  4160. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4161. // A link to the file that contains logs of the CreateMLModel operation.
  4162. LogUri *string `type:"string"`
  4163. // The MLModel ID, which is same as the MLModelId in the request.
  4164. MLModelId *string `min:"1" type:"string"`
  4165. // Identifies the MLModel category. The following are the available types:
  4166. //
  4167. // * REGRESSION -- Produces a numeric result. For example, "What price should
  4168. // a house be listed at?"
  4169. // * BINARY -- Produces one of two possible results. For example, "Is this
  4170. // an e-commerce website?"
  4171. // * MULTICLASS -- Produces one of several possible results. For example,
  4172. // "Is this a HIGH, LOW or MEDIUM risk trade?"
  4173. MLModelType *string `type:"string" enum:"MLModelType"`
  4174. // A description of the most recent details about accessing the MLModel.
  4175. Message *string `type:"string"`
  4176. // A user-supplied name or description of the MLModel.
  4177. Name *string `type:"string"`
  4178. // The recipe to use when training the MLModel. The Recipe provides detailed
  4179. // information about the observation data to use during training, and manipulations
  4180. // to perform on the observation data during training.
  4181. //
  4182. // NoteThis parameter is provided as part of the verbose format.
  4183. Recipe *string `type:"string"`
  4184. // The schema used by all of the data files referenced by the DataSource.
  4185. //
  4186. // NoteThis parameter is provided as part of the verbose format.
  4187. Schema *string `type:"string"`
  4188. // The scoring threshold is used in binary classification MLModelmodels. It
  4189. // marks the boundary between a positive prediction and a negative prediction.
  4190. //
  4191. // Output values greater than or equal to the threshold receive a positive result
  4192. // from the MLModel, such as true. Output values less than the threshold receive
  4193. // a negative response from the MLModel, such as false.
  4194. ScoreThreshold *float64 `type:"float"`
  4195. // The time of the most recent edit to the ScoreThreshold. The time is expressed
  4196. // in epoch time.
  4197. ScoreThresholdLastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4198. // Long integer type that is a 64-bit signed number.
  4199. SizeInBytes *int64 `type:"long"`
  4200. // The epoch time when Amazon Machine Learning marked the MLModel as INPROGRESS.
  4201. // StartedAt isn't available if the MLModel is in the PENDING state.
  4202. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4203. // The current status of the MLModel. This element can have one of the following
  4204. // values:
  4205. //
  4206. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  4207. // describe a MLModel.
  4208. // * INPROGRESS - The request is processing.
  4209. // * FAILED - The request did not run to completion. The ML model isn't usable.
  4210. //
  4211. // * COMPLETED - The request completed successfully.
  4212. // * DELETED - The MLModel is marked as deleted. It isn't usable.
  4213. Status *string `type:"string" enum:"EntityStatus"`
  4214. // The ID of the training DataSource.
  4215. TrainingDataSourceId *string `min:"1" type:"string"`
  4216. // A list of the training parameters in the MLModel. The list is implemented
  4217. // as a map of key-value pairs.
  4218. //
  4219. // The following is the current set of training parameters:
  4220. //
  4221. // * sgd.maxMLModelSizeInBytes - The maximum allowed size of the model. Depending
  4222. // on the input data, the size of the model might affect its performance.
  4223. //
  4224. // The value is an integer that ranges from 100000 to 2147483648. The default
  4225. // value is 33554432.
  4226. //
  4227. // * sgd.maxPasses - The number of times that the training process traverses
  4228. // the observations to build the MLModel. The value is an integer that ranges
  4229. // from 1 to 10000. The default value is 10.
  4230. //
  4231. // * sgd.shuffleType - Whether Amazon ML shuffles the training data. Shuffling
  4232. // data improves a model's ability to find the optimal solution for a variety
  4233. // of data types. The valid values are auto and none. The default value is
  4234. // none. We strongly recommend that you shuffle your data.
  4235. //
  4236. // * sgd.l1RegularizationAmount - The coefficient regularization L1 norm.
  4237. // It controls overfitting the data by penalizing large coefficients. This
  4238. // tends to drive coefficients to zero, resulting in a sparse feature set.
  4239. // If you use this parameter, start by specifying a small value, such as
  4240. // 1.0E-08.
  4241. //
  4242. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  4243. // not use L1 normalization. This parameter can't be used when L2 is specified.
  4244. // Use this parameter sparingly.
  4245. //
  4246. // * sgd.l2RegularizationAmount - The coefficient regularization L2 norm.
  4247. // It controls overfitting the data by penalizing large coefficients. This
  4248. // tends to drive coefficients to small, nonzero values. If you use this
  4249. // parameter, start by specifying a small value, such as 1.0E-08.
  4250. //
  4251. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  4252. // not use L2 normalization. This parameter can't be used when L1 is specified.
  4253. // Use this parameter sparingly.
  4254. TrainingParameters map[string]*string `type:"map"`
  4255. }
  4256. // String returns the string representation
  4257. func (s GetMLModelOutput) String() string {
  4258. return awsutil.Prettify(s)
  4259. }
  4260. // GoString returns the string representation
  4261. func (s GetMLModelOutput) GoString() string {
  4262. return s.String()
  4263. }
  4264. // Represents the output of a GetMLModel operation.
  4265. //
  4266. // The content consists of the detailed metadata and the current status of the
  4267. // MLModel.
  4268. type MLModel struct {
  4269. _ struct{} `type:"structure"`
  4270. // The algorithm used to train the MLModel. The following algorithm is supported:
  4271. //
  4272. // * SGD -- Stochastic gradient descent. The goal of SGD is to minimize the
  4273. // gradient of the loss function.
  4274. Algorithm *string `type:"string" enum:"Algorithm"`
  4275. // Long integer type that is a 64-bit signed number.
  4276. ComputeTime *int64 `type:"long"`
  4277. // The time that the MLModel was created. The time is expressed in epoch time.
  4278. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4279. // The AWS user account from which the MLModel was created. The account type
  4280. // can be either an AWS root account or an AWS Identity and Access Management
  4281. // (IAM) user account.
  4282. CreatedByIamUser *string `type:"string"`
  4283. // The current endpoint of the MLModel.
  4284. EndpointInfo *RealtimeEndpointInfo `type:"structure"`
  4285. // A timestamp represented in epoch time.
  4286. FinishedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4287. // The location of the data file or directory in Amazon Simple Storage Service
  4288. // (Amazon S3).
  4289. InputDataLocationS3 *string `type:"string"`
  4290. // The time of the most recent edit to the MLModel. The time is expressed in
  4291. // epoch time.
  4292. LastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4293. // The ID assigned to the MLModel at creation.
  4294. MLModelId *string `min:"1" type:"string"`
  4295. // Identifies the MLModel category. The following are the available types:
  4296. //
  4297. // * REGRESSION - Produces a numeric result. For example, "What price should
  4298. // a house be listed at?"
  4299. // * BINARY - Produces one of two possible results. For example, "Is this
  4300. // a child-friendly web site?".
  4301. // * MULTICLASS - Produces one of several possible results. For example,
  4302. // "Is this a HIGH-, LOW-, or MEDIUM-risk trade?".
  4303. MLModelType *string `type:"string" enum:"MLModelType"`
  4304. // A description of the most recent details about accessing the MLModel.
  4305. Message *string `type:"string"`
  4306. // A user-supplied name or description of the MLModel.
  4307. Name *string `type:"string"`
  4308. ScoreThreshold *float64 `type:"float"`
  4309. // The time of the most recent edit to the ScoreThreshold. The time is expressed
  4310. // in epoch time.
  4311. ScoreThresholdLastUpdatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4312. // Long integer type that is a 64-bit signed number.
  4313. SizeInBytes *int64 `type:"long"`
  4314. // A timestamp represented in epoch time.
  4315. StartedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4316. // The current status of an MLModel. This element can have one of the following
  4317. // values:
  4318. //
  4319. // * PENDING - Amazon Machine Learning (Amazon ML) submitted a request to
  4320. // create an MLModel.
  4321. // * INPROGRESS - The creation process is underway.
  4322. // * FAILED - The request to create an MLModel didn't run to completion.
  4323. // The model isn't usable.
  4324. // * COMPLETED - The creation process completed successfully.
  4325. // * DELETED - The MLModel is marked as deleted. It isn't usable.
  4326. Status *string `type:"string" enum:"EntityStatus"`
  4327. // The ID of the training DataSource. The CreateMLModel operation uses the TrainingDataSourceId.
  4328. TrainingDataSourceId *string `min:"1" type:"string"`
  4329. // A list of the training parameters in the MLModel. The list is implemented
  4330. // as a map of key-value pairs.
  4331. //
  4332. // The following is the current set of training parameters:
  4333. //
  4334. // * sgd.maxMLModelSizeInBytes - The maximum allowed size of the model. Depending
  4335. // on the input data, the size of the model might affect its performance.
  4336. //
  4337. // The value is an integer that ranges from 100000 to 2147483648. The default
  4338. // value is 33554432.
  4339. //
  4340. // * sgd.maxPasses - The number of times that the training process traverses
  4341. // the observations to build the MLModel. The value is an integer that ranges
  4342. // from 1 to 10000. The default value is 10.
  4343. //
  4344. // * sgd.shuffleType - Whether Amazon ML shuffles the training data. Shuffling
  4345. // the data improves a model's ability to find the optimal solution for a
  4346. // variety of data types. The valid values are auto and none. The default
  4347. // value is none.
  4348. //
  4349. // * sgd.l1RegularizationAmount - The coefficient regularization L1 norm,
  4350. // which controls overfitting the data by penalizing large coefficients.
  4351. // This parameter tends to drive coefficients to zero, resulting in sparse
  4352. // feature set. If you use this parameter, start by specifying a small value,
  4353. // such as 1.0E-08.
  4354. //
  4355. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  4356. // not use L1 normalization. This parameter can't be used when L2 is specified.
  4357. // Use this parameter sparingly.
  4358. //
  4359. // * sgd.l2RegularizationAmount - The coefficient regularization L2 norm,
  4360. // which controls overfitting the data by penalizing large coefficients.
  4361. // This tends to drive coefficients to small, nonzero values. If you use
  4362. // this parameter, start by specifying a small value, such as 1.0E-08.
  4363. //
  4364. // The value is a double that ranges from 0 to MAX_DOUBLE. The default is to
  4365. // not use L2 normalization. This parameter can't be used when L1 is specified.
  4366. // Use this parameter sparingly.
  4367. TrainingParameters map[string]*string `type:"map"`
  4368. }
  4369. // String returns the string representation
  4370. func (s MLModel) String() string {
  4371. return awsutil.Prettify(s)
  4372. }
  4373. // GoString returns the string representation
  4374. func (s MLModel) GoString() string {
  4375. return s.String()
  4376. }
  4377. // Measurements of how well the MLModel performed on known observations. One
  4378. // of the following metrics is returned, based on the type of the MLModel:
  4379. //
  4380. // * BinaryAUC: The binary MLModel uses the Area Under the Curve (AUC) technique
  4381. // to measure performance.
  4382. //
  4383. // * RegressionRMSE: The regression MLModel uses the Root Mean Square Error
  4384. // (RMSE) technique to measure performance. RMSE measures the difference
  4385. // between predicted and actual values for a single variable.
  4386. //
  4387. // * MulticlassAvgFScore: The multiclass MLModel uses the F1 score technique
  4388. // to measure performance.
  4389. //
  4390. // For more information about performance metrics, please see the Amazon Machine
  4391. // Learning Developer Guide (http://docs.aws.amazon.com/machine-learning/latest/dg).
  4392. type PerformanceMetrics struct {
  4393. _ struct{} `type:"structure"`
  4394. Properties map[string]*string `type:"map"`
  4395. }
  4396. // String returns the string representation
  4397. func (s PerformanceMetrics) String() string {
  4398. return awsutil.Prettify(s)
  4399. }
  4400. // GoString returns the string representation
  4401. func (s PerformanceMetrics) GoString() string {
  4402. return s.String()
  4403. }
  4404. type PredictInput struct {
  4405. _ struct{} `type:"structure"`
  4406. // A unique identifier of the MLModel.
  4407. //
  4408. // MLModelId is a required field
  4409. MLModelId *string `min:"1" type:"string" required:"true"`
  4410. // PredictEndpoint is a required field
  4411. PredictEndpoint *string `type:"string" required:"true"`
  4412. // A map of variable name-value pairs that represent an observation.
  4413. //
  4414. // Record is a required field
  4415. Record map[string]*string `type:"map" required:"true"`
  4416. }
  4417. // String returns the string representation
  4418. func (s PredictInput) String() string {
  4419. return awsutil.Prettify(s)
  4420. }
  4421. // GoString returns the string representation
  4422. func (s PredictInput) GoString() string {
  4423. return s.String()
  4424. }
  4425. // Validate inspects the fields of the type to determine if they are valid.
  4426. func (s *PredictInput) Validate() error {
  4427. invalidParams := request.ErrInvalidParams{Context: "PredictInput"}
  4428. if s.MLModelId == nil {
  4429. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  4430. }
  4431. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  4432. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  4433. }
  4434. if s.PredictEndpoint == nil {
  4435. invalidParams.Add(request.NewErrParamRequired("PredictEndpoint"))
  4436. }
  4437. if s.Record == nil {
  4438. invalidParams.Add(request.NewErrParamRequired("Record"))
  4439. }
  4440. if invalidParams.Len() > 0 {
  4441. return invalidParams
  4442. }
  4443. return nil
  4444. }
  4445. type PredictOutput struct {
  4446. _ struct{} `type:"structure"`
  4447. // The output from a Predict operation:
  4448. //
  4449. // * Details - Contains the following attributes: DetailsAttributes.PREDICTIVE_MODEL_TYPE
  4450. // - REGRESSION | BINARY | MULTICLASSDetailsAttributes.ALGORITHM - SGD
  4451. //
  4452. // * PredictedLabel - Present for either a BINARY or MULTICLASSMLModel request.
  4453. //
  4454. //
  4455. // * PredictedScores - Contains the raw classification score corresponding
  4456. // to each label.
  4457. //
  4458. // * PredictedValue - Present for a REGRESSIONMLModel request.
  4459. Prediction *Prediction `type:"structure"`
  4460. }
  4461. // String returns the string representation
  4462. func (s PredictOutput) String() string {
  4463. return awsutil.Prettify(s)
  4464. }
  4465. // GoString returns the string representation
  4466. func (s PredictOutput) GoString() string {
  4467. return s.String()
  4468. }
  4469. // The output from a Predict operation:
  4470. //
  4471. // * Details - Contains the following attributes: DetailsAttributes.PREDICTIVE_MODEL_TYPE
  4472. // - REGRESSION | BINARY | MULTICLASSDetailsAttributes.ALGORITHM - SGD
  4473. //
  4474. // * PredictedLabel - Present for either a BINARY or MULTICLASSMLModel request.
  4475. //
  4476. //
  4477. // * PredictedScores - Contains the raw classification score corresponding
  4478. // to each label.
  4479. //
  4480. // * PredictedValue - Present for a REGRESSIONMLModel request.
  4481. type Prediction struct {
  4482. _ struct{} `type:"structure"`
  4483. // Provides any additional details regarding the prediction.
  4484. Details map[string]*string `locationName:"details" type:"map"`
  4485. // The prediction label for either a BINARY or MULTICLASSMLModel.
  4486. PredictedLabel *string `locationName:"predictedLabel" min:"1" type:"string"`
  4487. // Provides the raw classification score corresponding to each label.
  4488. PredictedScores map[string]*float64 `locationName:"predictedScores" type:"map"`
  4489. // The prediction value for REGRESSIONMLModel
  4490. PredictedValue *float64 `locationName:"predictedValue" type:"float"`
  4491. }
  4492. // String returns the string representation
  4493. func (s Prediction) String() string {
  4494. return awsutil.Prettify(s)
  4495. }
  4496. // GoString returns the string representation
  4497. func (s Prediction) GoString() string {
  4498. return s.String()
  4499. }
  4500. // The data specification of an Amazon Relational Database Service (Amazon RDS)
  4501. // DataSource.
  4502. type RDSDataSpec struct {
  4503. _ struct{} `type:"structure"`
  4504. // A JSON string that represents the splitting and rearrangement processing
  4505. // to be applied to a DataSource. If the DataRearrangement parameter is not
  4506. // provided, all of the input data is used to create the Datasource.
  4507. //
  4508. // There are multiple parameters that control what data is used to create a
  4509. // datasource:
  4510. //
  4511. // * percentBegin
  4512. //
  4513. // Use percentBegin to indicate the beginning of the range of the data used
  4514. // to create the Datasource. If you do not include percentBegin and percentEnd,
  4515. // Amazon ML includes all of the data when creating the datasource.
  4516. //
  4517. // * percentEnd
  4518. //
  4519. // Use percentEnd to indicate the end of the range of the data used to create
  4520. // the Datasource. If you do not include percentBegin and percentEnd, Amazon
  4521. // ML includes all of the data when creating the datasource.
  4522. //
  4523. // * complement
  4524. //
  4525. // The complement parameter instructs Amazon ML to use the data that is not
  4526. // included in the range of percentBegin to percentEnd to create a datasource.
  4527. // The complement parameter is useful if you need to create complementary
  4528. // datasources for training and evaluation. To create a complementary datasource,
  4529. // use the same values for percentBegin and percentEnd, along with the complement
  4530. // parameter.
  4531. //
  4532. // For example, the following two datasources do not share any data, and can
  4533. // be used to train and evaluate a model. The first datasource has 25 percent
  4534. // of the data, and the second one has 75 percent of the data.
  4535. //
  4536. // Datasource for evaluation: {"splitting":{"percentBegin":0, "percentEnd":25}}
  4537. //
  4538. // Datasource for training: {"splitting":{"percentBegin":0, "percentEnd":25,
  4539. // "complement":"true"}}
  4540. //
  4541. // * strategy
  4542. //
  4543. // To change how Amazon ML splits the data for a datasource, use the strategy
  4544. // parameter.
  4545. //
  4546. // The default value for the strategy parameter is sequential, meaning that
  4547. // Amazon ML takes all of the data records between the percentBegin and percentEnd
  4548. // parameters for the datasource, in the order that the records appear in
  4549. // the input data.
  4550. //
  4551. // The following two DataRearrangement lines are examples of sequentially ordered
  4552. // training and evaluation datasources:
  4553. //
  4554. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  4555. // "strategy":"sequential"}}
  4556. //
  4557. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  4558. // "strategy":"sequential", "complement":"true"}}
  4559. //
  4560. // To randomly split the input data into the proportions indicated by the percentBegin
  4561. // and percentEnd parameters, set the strategy parameter to random and provide
  4562. // a string that is used as the seed value for the random data splitting
  4563. // (for example, you can use the S3 path to your data as the random seed
  4564. // string). If you choose the random split strategy, Amazon ML assigns each
  4565. // row of data a pseudo-random number between 0 and 100, and then selects
  4566. // the rows that have an assigned number between percentBegin and percentEnd.
  4567. // Pseudo-random numbers are assigned using both the input seed string value
  4568. // and the byte offset as a seed, so changing the data results in a different
  4569. // split. Any existing ordering is preserved. The random splitting strategy
  4570. // ensures that variables in the training and evaluation data are distributed
  4571. // similarly. It is useful in the cases where the input data may have an
  4572. // implicit sort order, which would otherwise result in training and evaluation
  4573. // datasources containing non-similar data records.
  4574. //
  4575. // The following two DataRearrangement lines are examples of non-sequentially
  4576. // ordered training and evaluation datasources:
  4577. //
  4578. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  4579. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv"}}
  4580. //
  4581. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  4582. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv", "complement":"true"}}
  4583. DataRearrangement *string `type:"string"`
  4584. // A JSON string that represents the schema for an Amazon RDS DataSource. The
  4585. // DataSchema defines the structure of the observation data in the data file(s)
  4586. // referenced in the DataSource.
  4587. //
  4588. // A DataSchema is not required if you specify a DataSchemaUri
  4589. //
  4590. // Define your DataSchema as a series of key-value pairs. attributes and excludedVariableNames
  4591. // have an array of key-value pairs for their value. Use the following format
  4592. // to define your DataSchema.
  4593. //
  4594. // { "version": "1.0",
  4595. //
  4596. // "recordAnnotationFieldName": "F1",
  4597. //
  4598. // "recordWeightFieldName": "F2",
  4599. //
  4600. // "targetFieldName": "F3",
  4601. //
  4602. // "dataFormat": "CSV",
  4603. //
  4604. // "dataFileContainsHeader": true,
  4605. //
  4606. // "attributes": [
  4607. //
  4608. // { "fieldName": "F1", "fieldType": "TEXT" }, { "fieldName": "F2", "fieldType":
  4609. // "NUMERIC" }, { "fieldName": "F3", "fieldType": "CATEGORICAL" }, { "fieldName":
  4610. // "F4", "fieldType": "NUMERIC" }, { "fieldName": "F5", "fieldType": "CATEGORICAL"
  4611. // }, { "fieldName": "F6", "fieldType": "TEXT" }, { "fieldName": "F7", "fieldType":
  4612. // "WEIGHTED_INT_SEQUENCE" }, { "fieldName": "F8", "fieldType": "WEIGHTED_STRING_SEQUENCE"
  4613. // } ],
  4614. //
  4615. // "excludedVariableNames": [ "F6" ] }
  4616. DataSchema *string `type:"string"`
  4617. // The Amazon S3 location of the DataSchema.
  4618. DataSchemaUri *string `type:"string"`
  4619. // The AWS Identity and Access Management (IAM) credentials that are used connect
  4620. // to the Amazon RDS database.
  4621. //
  4622. // DatabaseCredentials is a required field
  4623. DatabaseCredentials *RDSDatabaseCredentials `type:"structure" required:"true"`
  4624. // Describes the DatabaseName and InstanceIdentifier of an Amazon RDS database.
  4625. //
  4626. // DatabaseInformation is a required field
  4627. DatabaseInformation *RDSDatabase `type:"structure" required:"true"`
  4628. // The role (DataPipelineDefaultResourceRole) assumed by an Amazon Elastic Compute
  4629. // Cloud (Amazon EC2) instance to carry out the copy operation from Amazon RDS
  4630. // to an Amazon S3 task. For more information, see Role templates (http://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
  4631. // for data pipelines.
  4632. //
  4633. // ResourceRole is a required field
  4634. ResourceRole *string `min:"1" type:"string" required:"true"`
  4635. // The Amazon S3 location for staging Amazon RDS data. The data retrieved from
  4636. // Amazon RDS using SelectSqlQuery is stored in this location.
  4637. //
  4638. // S3StagingLocation is a required field
  4639. S3StagingLocation *string `type:"string" required:"true"`
  4640. // The security group IDs to be used to access a VPC-based RDS DB instance.
  4641. // Ensure that there are appropriate ingress rules set up to allow access to
  4642. // the RDS DB instance. This attribute is used by Data Pipeline to carry out
  4643. // the copy operation from Amazon RDS to an Amazon S3 task.
  4644. //
  4645. // SecurityGroupIds is a required field
  4646. SecurityGroupIds []*string `type:"list" required:"true"`
  4647. // The query that is used to retrieve the observation data for the DataSource.
  4648. //
  4649. // SelectSqlQuery is a required field
  4650. SelectSqlQuery *string `min:"1" type:"string" required:"true"`
  4651. // The role (DataPipelineDefaultRole) assumed by AWS Data Pipeline service to
  4652. // monitor the progress of the copy task from Amazon RDS to Amazon S3. For more
  4653. // information, see Role templates (http://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
  4654. // for data pipelines.
  4655. //
  4656. // ServiceRole is a required field
  4657. ServiceRole *string `min:"1" type:"string" required:"true"`
  4658. // The subnet ID to be used to access a VPC-based RDS DB instance. This attribute
  4659. // is used by Data Pipeline to carry out the copy task from Amazon RDS to Amazon
  4660. // S3.
  4661. //
  4662. // SubnetId is a required field
  4663. SubnetId *string `min:"1" type:"string" required:"true"`
  4664. }
  4665. // String returns the string representation
  4666. func (s RDSDataSpec) String() string {
  4667. return awsutil.Prettify(s)
  4668. }
  4669. // GoString returns the string representation
  4670. func (s RDSDataSpec) GoString() string {
  4671. return s.String()
  4672. }
  4673. // Validate inspects the fields of the type to determine if they are valid.
  4674. func (s *RDSDataSpec) Validate() error {
  4675. invalidParams := request.ErrInvalidParams{Context: "RDSDataSpec"}
  4676. if s.DatabaseCredentials == nil {
  4677. invalidParams.Add(request.NewErrParamRequired("DatabaseCredentials"))
  4678. }
  4679. if s.DatabaseInformation == nil {
  4680. invalidParams.Add(request.NewErrParamRequired("DatabaseInformation"))
  4681. }
  4682. if s.ResourceRole == nil {
  4683. invalidParams.Add(request.NewErrParamRequired("ResourceRole"))
  4684. }
  4685. if s.ResourceRole != nil && len(*s.ResourceRole) < 1 {
  4686. invalidParams.Add(request.NewErrParamMinLen("ResourceRole", 1))
  4687. }
  4688. if s.S3StagingLocation == nil {
  4689. invalidParams.Add(request.NewErrParamRequired("S3StagingLocation"))
  4690. }
  4691. if s.SecurityGroupIds == nil {
  4692. invalidParams.Add(request.NewErrParamRequired("SecurityGroupIds"))
  4693. }
  4694. if s.SelectSqlQuery == nil {
  4695. invalidParams.Add(request.NewErrParamRequired("SelectSqlQuery"))
  4696. }
  4697. if s.SelectSqlQuery != nil && len(*s.SelectSqlQuery) < 1 {
  4698. invalidParams.Add(request.NewErrParamMinLen("SelectSqlQuery", 1))
  4699. }
  4700. if s.ServiceRole == nil {
  4701. invalidParams.Add(request.NewErrParamRequired("ServiceRole"))
  4702. }
  4703. if s.ServiceRole != nil && len(*s.ServiceRole) < 1 {
  4704. invalidParams.Add(request.NewErrParamMinLen("ServiceRole", 1))
  4705. }
  4706. if s.SubnetId == nil {
  4707. invalidParams.Add(request.NewErrParamRequired("SubnetId"))
  4708. }
  4709. if s.SubnetId != nil && len(*s.SubnetId) < 1 {
  4710. invalidParams.Add(request.NewErrParamMinLen("SubnetId", 1))
  4711. }
  4712. if s.DatabaseCredentials != nil {
  4713. if err := s.DatabaseCredentials.Validate(); err != nil {
  4714. invalidParams.AddNested("DatabaseCredentials", err.(request.ErrInvalidParams))
  4715. }
  4716. }
  4717. if s.DatabaseInformation != nil {
  4718. if err := s.DatabaseInformation.Validate(); err != nil {
  4719. invalidParams.AddNested("DatabaseInformation", err.(request.ErrInvalidParams))
  4720. }
  4721. }
  4722. if invalidParams.Len() > 0 {
  4723. return invalidParams
  4724. }
  4725. return nil
  4726. }
  4727. // The database details of an Amazon RDS database.
  4728. type RDSDatabase struct {
  4729. _ struct{} `type:"structure"`
  4730. // The name of a database hosted on an RDS DB instance.
  4731. //
  4732. // DatabaseName is a required field
  4733. DatabaseName *string `min:"1" type:"string" required:"true"`
  4734. // The ID of an RDS DB instance.
  4735. //
  4736. // InstanceIdentifier is a required field
  4737. InstanceIdentifier *string `min:"1" type:"string" required:"true"`
  4738. }
  4739. // String returns the string representation
  4740. func (s RDSDatabase) String() string {
  4741. return awsutil.Prettify(s)
  4742. }
  4743. // GoString returns the string representation
  4744. func (s RDSDatabase) GoString() string {
  4745. return s.String()
  4746. }
  4747. // Validate inspects the fields of the type to determine if they are valid.
  4748. func (s *RDSDatabase) Validate() error {
  4749. invalidParams := request.ErrInvalidParams{Context: "RDSDatabase"}
  4750. if s.DatabaseName == nil {
  4751. invalidParams.Add(request.NewErrParamRequired("DatabaseName"))
  4752. }
  4753. if s.DatabaseName != nil && len(*s.DatabaseName) < 1 {
  4754. invalidParams.Add(request.NewErrParamMinLen("DatabaseName", 1))
  4755. }
  4756. if s.InstanceIdentifier == nil {
  4757. invalidParams.Add(request.NewErrParamRequired("InstanceIdentifier"))
  4758. }
  4759. if s.InstanceIdentifier != nil && len(*s.InstanceIdentifier) < 1 {
  4760. invalidParams.Add(request.NewErrParamMinLen("InstanceIdentifier", 1))
  4761. }
  4762. if invalidParams.Len() > 0 {
  4763. return invalidParams
  4764. }
  4765. return nil
  4766. }
  4767. // The database credentials to connect to a database on an RDS DB instance.
  4768. type RDSDatabaseCredentials struct {
  4769. _ struct{} `type:"structure"`
  4770. // The password to be used by Amazon ML to connect to a database on an RDS DB
  4771. // instance. The password should have sufficient permissions to execute the
  4772. // RDSSelectQuery query.
  4773. //
  4774. // Password is a required field
  4775. Password *string `min:"8" type:"string" required:"true"`
  4776. // The username to be used by Amazon ML to connect to database on an Amazon
  4777. // RDS instance. The username should have sufficient permissions to execute
  4778. // an RDSSelectSqlQuery query.
  4779. //
  4780. // Username is a required field
  4781. Username *string `min:"1" type:"string" required:"true"`
  4782. }
  4783. // String returns the string representation
  4784. func (s RDSDatabaseCredentials) String() string {
  4785. return awsutil.Prettify(s)
  4786. }
  4787. // GoString returns the string representation
  4788. func (s RDSDatabaseCredentials) GoString() string {
  4789. return s.String()
  4790. }
  4791. // Validate inspects the fields of the type to determine if they are valid.
  4792. func (s *RDSDatabaseCredentials) Validate() error {
  4793. invalidParams := request.ErrInvalidParams{Context: "RDSDatabaseCredentials"}
  4794. if s.Password == nil {
  4795. invalidParams.Add(request.NewErrParamRequired("Password"))
  4796. }
  4797. if s.Password != nil && len(*s.Password) < 8 {
  4798. invalidParams.Add(request.NewErrParamMinLen("Password", 8))
  4799. }
  4800. if s.Username == nil {
  4801. invalidParams.Add(request.NewErrParamRequired("Username"))
  4802. }
  4803. if s.Username != nil && len(*s.Username) < 1 {
  4804. invalidParams.Add(request.NewErrParamMinLen("Username", 1))
  4805. }
  4806. if invalidParams.Len() > 0 {
  4807. return invalidParams
  4808. }
  4809. return nil
  4810. }
  4811. // The datasource details that are specific to Amazon RDS.
  4812. type RDSMetadata struct {
  4813. _ struct{} `type:"structure"`
  4814. // The ID of the Data Pipeline instance that is used to carry to copy data from
  4815. // Amazon RDS to Amazon S3. You can use the ID to find details about the instance
  4816. // in the Data Pipeline console.
  4817. DataPipelineId *string `min:"1" type:"string"`
  4818. // The database details required to connect to an Amazon RDS.
  4819. Database *RDSDatabase `type:"structure"`
  4820. // The username to be used by Amazon ML to connect to database on an Amazon
  4821. // RDS instance. The username should have sufficient permissions to execute
  4822. // an RDSSelectSqlQuery query.
  4823. DatabaseUserName *string `min:"1" type:"string"`
  4824. // The role (DataPipelineDefaultResourceRole) assumed by an Amazon EC2 instance
  4825. // to carry out the copy task from Amazon RDS to Amazon S3. For more information,
  4826. // see Role templates (http://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
  4827. // for data pipelines.
  4828. ResourceRole *string `min:"1" type:"string"`
  4829. // The SQL query that is supplied during CreateDataSourceFromRDS. Returns only
  4830. // if Verbose is true in GetDataSourceInput.
  4831. SelectSqlQuery *string `min:"1" type:"string"`
  4832. // The role (DataPipelineDefaultRole) assumed by the Data Pipeline service to
  4833. // monitor the progress of the copy task from Amazon RDS to Amazon S3. For more
  4834. // information, see Role templates (http://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
  4835. // for data pipelines.
  4836. ServiceRole *string `min:"1" type:"string"`
  4837. }
  4838. // String returns the string representation
  4839. func (s RDSMetadata) String() string {
  4840. return awsutil.Prettify(s)
  4841. }
  4842. // GoString returns the string representation
  4843. func (s RDSMetadata) GoString() string {
  4844. return s.String()
  4845. }
  4846. // Describes the real-time endpoint information for an MLModel.
  4847. type RealtimeEndpointInfo struct {
  4848. _ struct{} `type:"structure"`
  4849. // The time that the request to create the real-time endpoint for the MLModel
  4850. // was received. The time is expressed in epoch time.
  4851. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"`
  4852. // The current status of the real-time endpoint for the MLModel. This element
  4853. // can have one of the following values:
  4854. //
  4855. // * NONE - Endpoint does not exist or was previously deleted.
  4856. // * READY - Endpoint is ready to be used for real-time predictions.
  4857. // * UPDATING - Updating/creating the endpoint.
  4858. EndpointStatus *string `type:"string" enum:"RealtimeEndpointStatus"`
  4859. // The URI that specifies where to send real-time prediction requests for the
  4860. // MLModel.
  4861. //
  4862. // NoteThe application must wait until the real-time endpoint is ready before
  4863. // using this URI.
  4864. EndpointUrl *string `type:"string"`
  4865. // The maximum processing rate for the real-time endpoint for MLModel, measured
  4866. // in incoming requests per second.
  4867. PeakRequestsPerSecond *int64 `type:"integer"`
  4868. }
  4869. // String returns the string representation
  4870. func (s RealtimeEndpointInfo) String() string {
  4871. return awsutil.Prettify(s)
  4872. }
  4873. // GoString returns the string representation
  4874. func (s RealtimeEndpointInfo) GoString() string {
  4875. return s.String()
  4876. }
  4877. // Describes the data specification of an Amazon Redshift DataSource.
  4878. type RedshiftDataSpec struct {
  4879. _ struct{} `type:"structure"`
  4880. // A JSON string that represents the splitting and rearrangement processing
  4881. // to be applied to a DataSource. If the DataRearrangement parameter is not
  4882. // provided, all of the input data is used to create the Datasource.
  4883. //
  4884. // There are multiple parameters that control what data is used to create a
  4885. // datasource:
  4886. //
  4887. // * percentBegin
  4888. //
  4889. // Use percentBegin to indicate the beginning of the range of the data used
  4890. // to create the Datasource. If you do not include percentBegin and percentEnd,
  4891. // Amazon ML includes all of the data when creating the datasource.
  4892. //
  4893. // * percentEnd
  4894. //
  4895. // Use percentEnd to indicate the end of the range of the data used to create
  4896. // the Datasource. If you do not include percentBegin and percentEnd, Amazon
  4897. // ML includes all of the data when creating the datasource.
  4898. //
  4899. // * complement
  4900. //
  4901. // The complement parameter instructs Amazon ML to use the data that is not
  4902. // included in the range of percentBegin to percentEnd to create a datasource.
  4903. // The complement parameter is useful if you need to create complementary
  4904. // datasources for training and evaluation. To create a complementary datasource,
  4905. // use the same values for percentBegin and percentEnd, along with the complement
  4906. // parameter.
  4907. //
  4908. // For example, the following two datasources do not share any data, and can
  4909. // be used to train and evaluate a model. The first datasource has 25 percent
  4910. // of the data, and the second one has 75 percent of the data.
  4911. //
  4912. // Datasource for evaluation: {"splitting":{"percentBegin":0, "percentEnd":25}}
  4913. //
  4914. // Datasource for training: {"splitting":{"percentBegin":0, "percentEnd":25,
  4915. // "complement":"true"}}
  4916. //
  4917. // * strategy
  4918. //
  4919. // To change how Amazon ML splits the data for a datasource, use the strategy
  4920. // parameter.
  4921. //
  4922. // The default value for the strategy parameter is sequential, meaning that
  4923. // Amazon ML takes all of the data records between the percentBegin and percentEnd
  4924. // parameters for the datasource, in the order that the records appear in
  4925. // the input data.
  4926. //
  4927. // The following two DataRearrangement lines are examples of sequentially ordered
  4928. // training and evaluation datasources:
  4929. //
  4930. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  4931. // "strategy":"sequential"}}
  4932. //
  4933. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  4934. // "strategy":"sequential", "complement":"true"}}
  4935. //
  4936. // To randomly split the input data into the proportions indicated by the percentBegin
  4937. // and percentEnd parameters, set the strategy parameter to random and provide
  4938. // a string that is used as the seed value for the random data splitting
  4939. // (for example, you can use the S3 path to your data as the random seed
  4940. // string). If you choose the random split strategy, Amazon ML assigns each
  4941. // row of data a pseudo-random number between 0 and 100, and then selects
  4942. // the rows that have an assigned number between percentBegin and percentEnd.
  4943. // Pseudo-random numbers are assigned using both the input seed string value
  4944. // and the byte offset as a seed, so changing the data results in a different
  4945. // split. Any existing ordering is preserved. The random splitting strategy
  4946. // ensures that variables in the training and evaluation data are distributed
  4947. // similarly. It is useful in the cases where the input data may have an
  4948. // implicit sort order, which would otherwise result in training and evaluation
  4949. // datasources containing non-similar data records.
  4950. //
  4951. // The following two DataRearrangement lines are examples of non-sequentially
  4952. // ordered training and evaluation datasources:
  4953. //
  4954. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  4955. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv"}}
  4956. //
  4957. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  4958. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv", "complement":"true"}}
  4959. DataRearrangement *string `type:"string"`
  4960. // A JSON string that represents the schema for an Amazon Redshift DataSource.
  4961. // The DataSchema defines the structure of the observation data in the data
  4962. // file(s) referenced in the DataSource.
  4963. //
  4964. // A DataSchema is not required if you specify a DataSchemaUri.
  4965. //
  4966. // Define your DataSchema as a series of key-value pairs. attributes and excludedVariableNames
  4967. // have an array of key-value pairs for their value. Use the following format
  4968. // to define your DataSchema.
  4969. //
  4970. // { "version": "1.0",
  4971. //
  4972. // "recordAnnotationFieldName": "F1",
  4973. //
  4974. // "recordWeightFieldName": "F2",
  4975. //
  4976. // "targetFieldName": "F3",
  4977. //
  4978. // "dataFormat": "CSV",
  4979. //
  4980. // "dataFileContainsHeader": true,
  4981. //
  4982. // "attributes": [
  4983. //
  4984. // { "fieldName": "F1", "fieldType": "TEXT" }, { "fieldName": "F2", "fieldType":
  4985. // "NUMERIC" }, { "fieldName": "F3", "fieldType": "CATEGORICAL" }, { "fieldName":
  4986. // "F4", "fieldType": "NUMERIC" }, { "fieldName": "F5", "fieldType": "CATEGORICAL"
  4987. // }, { "fieldName": "F6", "fieldType": "TEXT" }, { "fieldName": "F7", "fieldType":
  4988. // "WEIGHTED_INT_SEQUENCE" }, { "fieldName": "F8", "fieldType": "WEIGHTED_STRING_SEQUENCE"
  4989. // } ],
  4990. //
  4991. // "excludedVariableNames": [ "F6" ] }
  4992. DataSchema *string `type:"string"`
  4993. // Describes the schema location for an Amazon Redshift DataSource.
  4994. DataSchemaUri *string `type:"string"`
  4995. // Describes AWS Identity and Access Management (IAM) credentials that are used
  4996. // connect to the Amazon Redshift database.
  4997. //
  4998. // DatabaseCredentials is a required field
  4999. DatabaseCredentials *RedshiftDatabaseCredentials `type:"structure" required:"true"`
  5000. // Describes the DatabaseName and ClusterIdentifier for an Amazon Redshift DataSource.
  5001. //
  5002. // DatabaseInformation is a required field
  5003. DatabaseInformation *RedshiftDatabase `type:"structure" required:"true"`
  5004. // Describes an Amazon S3 location to store the result set of the SelectSqlQuery
  5005. // query.
  5006. //
  5007. // S3StagingLocation is a required field
  5008. S3StagingLocation *string `type:"string" required:"true"`
  5009. // Describes the SQL Query to execute on an Amazon Redshift database for an
  5010. // Amazon Redshift DataSource.
  5011. //
  5012. // SelectSqlQuery is a required field
  5013. SelectSqlQuery *string `min:"1" type:"string" required:"true"`
  5014. }
  5015. // String returns the string representation
  5016. func (s RedshiftDataSpec) String() string {
  5017. return awsutil.Prettify(s)
  5018. }
  5019. // GoString returns the string representation
  5020. func (s RedshiftDataSpec) GoString() string {
  5021. return s.String()
  5022. }
  5023. // Validate inspects the fields of the type to determine if they are valid.
  5024. func (s *RedshiftDataSpec) Validate() error {
  5025. invalidParams := request.ErrInvalidParams{Context: "RedshiftDataSpec"}
  5026. if s.DatabaseCredentials == nil {
  5027. invalidParams.Add(request.NewErrParamRequired("DatabaseCredentials"))
  5028. }
  5029. if s.DatabaseInformation == nil {
  5030. invalidParams.Add(request.NewErrParamRequired("DatabaseInformation"))
  5031. }
  5032. if s.S3StagingLocation == nil {
  5033. invalidParams.Add(request.NewErrParamRequired("S3StagingLocation"))
  5034. }
  5035. if s.SelectSqlQuery == nil {
  5036. invalidParams.Add(request.NewErrParamRequired("SelectSqlQuery"))
  5037. }
  5038. if s.SelectSqlQuery != nil && len(*s.SelectSqlQuery) < 1 {
  5039. invalidParams.Add(request.NewErrParamMinLen("SelectSqlQuery", 1))
  5040. }
  5041. if s.DatabaseCredentials != nil {
  5042. if err := s.DatabaseCredentials.Validate(); err != nil {
  5043. invalidParams.AddNested("DatabaseCredentials", err.(request.ErrInvalidParams))
  5044. }
  5045. }
  5046. if s.DatabaseInformation != nil {
  5047. if err := s.DatabaseInformation.Validate(); err != nil {
  5048. invalidParams.AddNested("DatabaseInformation", err.(request.ErrInvalidParams))
  5049. }
  5050. }
  5051. if invalidParams.Len() > 0 {
  5052. return invalidParams
  5053. }
  5054. return nil
  5055. }
  5056. // Describes the database details required to connect to an Amazon Redshift
  5057. // database.
  5058. type RedshiftDatabase struct {
  5059. _ struct{} `type:"structure"`
  5060. // The ID of an Amazon Redshift cluster.
  5061. //
  5062. // ClusterIdentifier is a required field
  5063. ClusterIdentifier *string `min:"1" type:"string" required:"true"`
  5064. // The name of a database hosted on an Amazon Redshift cluster.
  5065. //
  5066. // DatabaseName is a required field
  5067. DatabaseName *string `min:"1" type:"string" required:"true"`
  5068. }
  5069. // String returns the string representation
  5070. func (s RedshiftDatabase) String() string {
  5071. return awsutil.Prettify(s)
  5072. }
  5073. // GoString returns the string representation
  5074. func (s RedshiftDatabase) GoString() string {
  5075. return s.String()
  5076. }
  5077. // Validate inspects the fields of the type to determine if they are valid.
  5078. func (s *RedshiftDatabase) Validate() error {
  5079. invalidParams := request.ErrInvalidParams{Context: "RedshiftDatabase"}
  5080. if s.ClusterIdentifier == nil {
  5081. invalidParams.Add(request.NewErrParamRequired("ClusterIdentifier"))
  5082. }
  5083. if s.ClusterIdentifier != nil && len(*s.ClusterIdentifier) < 1 {
  5084. invalidParams.Add(request.NewErrParamMinLen("ClusterIdentifier", 1))
  5085. }
  5086. if s.DatabaseName == nil {
  5087. invalidParams.Add(request.NewErrParamRequired("DatabaseName"))
  5088. }
  5089. if s.DatabaseName != nil && len(*s.DatabaseName) < 1 {
  5090. invalidParams.Add(request.NewErrParamMinLen("DatabaseName", 1))
  5091. }
  5092. if invalidParams.Len() > 0 {
  5093. return invalidParams
  5094. }
  5095. return nil
  5096. }
  5097. // Describes the database credentials for connecting to a database on an Amazon
  5098. // Redshift cluster.
  5099. type RedshiftDatabaseCredentials struct {
  5100. _ struct{} `type:"structure"`
  5101. // A password to be used by Amazon ML to connect to a database on an Amazon
  5102. // Redshift cluster. The password should have sufficient permissions to execute
  5103. // a RedshiftSelectSqlQuery query. The password should be valid for an Amazon
  5104. // Redshift USER (http://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_USER.html).
  5105. //
  5106. // Password is a required field
  5107. Password *string `min:"8" type:"string" required:"true"`
  5108. // A username to be used by Amazon Machine Learning (Amazon ML)to connect to
  5109. // a database on an Amazon Redshift cluster. The username should have sufficient
  5110. // permissions to execute the RedshiftSelectSqlQuery query. The username should
  5111. // be valid for an Amazon Redshift USER (http://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_USER.html).
  5112. //
  5113. // Username is a required field
  5114. Username *string `min:"1" type:"string" required:"true"`
  5115. }
  5116. // String returns the string representation
  5117. func (s RedshiftDatabaseCredentials) String() string {
  5118. return awsutil.Prettify(s)
  5119. }
  5120. // GoString returns the string representation
  5121. func (s RedshiftDatabaseCredentials) GoString() string {
  5122. return s.String()
  5123. }
  5124. // Validate inspects the fields of the type to determine if they are valid.
  5125. func (s *RedshiftDatabaseCredentials) Validate() error {
  5126. invalidParams := request.ErrInvalidParams{Context: "RedshiftDatabaseCredentials"}
  5127. if s.Password == nil {
  5128. invalidParams.Add(request.NewErrParamRequired("Password"))
  5129. }
  5130. if s.Password != nil && len(*s.Password) < 8 {
  5131. invalidParams.Add(request.NewErrParamMinLen("Password", 8))
  5132. }
  5133. if s.Username == nil {
  5134. invalidParams.Add(request.NewErrParamRequired("Username"))
  5135. }
  5136. if s.Username != nil && len(*s.Username) < 1 {
  5137. invalidParams.Add(request.NewErrParamMinLen("Username", 1))
  5138. }
  5139. if invalidParams.Len() > 0 {
  5140. return invalidParams
  5141. }
  5142. return nil
  5143. }
  5144. // Describes the DataSource details specific to Amazon Redshift.
  5145. type RedshiftMetadata struct {
  5146. _ struct{} `type:"structure"`
  5147. // A username to be used by Amazon Machine Learning (Amazon ML)to connect to
  5148. // a database on an Amazon Redshift cluster. The username should have sufficient
  5149. // permissions to execute the RedshiftSelectSqlQuery query. The username should
  5150. // be valid for an Amazon Redshift USER (http://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_USER.html).
  5151. DatabaseUserName *string `min:"1" type:"string"`
  5152. // Describes the database details required to connect to an Amazon Redshift
  5153. // database.
  5154. RedshiftDatabase *RedshiftDatabase `type:"structure"`
  5155. // The SQL query that is specified during CreateDataSourceFromRedshift. Returns
  5156. // only if Verbose is true in GetDataSourceInput.
  5157. SelectSqlQuery *string `min:"1" type:"string"`
  5158. }
  5159. // String returns the string representation
  5160. func (s RedshiftMetadata) String() string {
  5161. return awsutil.Prettify(s)
  5162. }
  5163. // GoString returns the string representation
  5164. func (s RedshiftMetadata) GoString() string {
  5165. return s.String()
  5166. }
  5167. // Describes the data specification of a DataSource.
  5168. type S3DataSpec struct {
  5169. _ struct{} `type:"structure"`
  5170. // The location of the data file(s) used by a DataSource. The URI specifies
  5171. // a data file or an Amazon Simple Storage Service (Amazon S3) directory or
  5172. // bucket containing data files.
  5173. //
  5174. // DataLocationS3 is a required field
  5175. DataLocationS3 *string `type:"string" required:"true"`
  5176. // A JSON string that represents the splitting and rearrangement processing
  5177. // to be applied to a DataSource. If the DataRearrangement parameter is not
  5178. // provided, all of the input data is used to create the Datasource.
  5179. //
  5180. // There are multiple parameters that control what data is used to create a
  5181. // datasource:
  5182. //
  5183. // * percentBegin
  5184. //
  5185. // Use percentBegin to indicate the beginning of the range of the data used
  5186. // to create the Datasource. If you do not include percentBegin and percentEnd,
  5187. // Amazon ML includes all of the data when creating the datasource.
  5188. //
  5189. // * percentEnd
  5190. //
  5191. // Use percentEnd to indicate the end of the range of the data used to create
  5192. // the Datasource. If you do not include percentBegin and percentEnd, Amazon
  5193. // ML includes all of the data when creating the datasource.
  5194. //
  5195. // * complement
  5196. //
  5197. // The complement parameter instructs Amazon ML to use the data that is not
  5198. // included in the range of percentBegin to percentEnd to create a datasource.
  5199. // The complement parameter is useful if you need to create complementary
  5200. // datasources for training and evaluation. To create a complementary datasource,
  5201. // use the same values for percentBegin and percentEnd, along with the complement
  5202. // parameter.
  5203. //
  5204. // For example, the following two datasources do not share any data, and can
  5205. // be used to train and evaluate a model. The first datasource has 25 percent
  5206. // of the data, and the second one has 75 percent of the data.
  5207. //
  5208. // Datasource for evaluation: {"splitting":{"percentBegin":0, "percentEnd":25}}
  5209. //
  5210. // Datasource for training: {"splitting":{"percentBegin":0, "percentEnd":25,
  5211. // "complement":"true"}}
  5212. //
  5213. // * strategy
  5214. //
  5215. // To change how Amazon ML splits the data for a datasource, use the strategy
  5216. // parameter.
  5217. //
  5218. // The default value for the strategy parameter is sequential, meaning that
  5219. // Amazon ML takes all of the data records between the percentBegin and percentEnd
  5220. // parameters for the datasource, in the order that the records appear in
  5221. // the input data.
  5222. //
  5223. // The following two DataRearrangement lines are examples of sequentially ordered
  5224. // training and evaluation datasources:
  5225. //
  5226. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  5227. // "strategy":"sequential"}}
  5228. //
  5229. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  5230. // "strategy":"sequential", "complement":"true"}}
  5231. //
  5232. // To randomly split the input data into the proportions indicated by the percentBegin
  5233. // and percentEnd parameters, set the strategy parameter to random and provide
  5234. // a string that is used as the seed value for the random data splitting
  5235. // (for example, you can use the S3 path to your data as the random seed
  5236. // string). If you choose the random split strategy, Amazon ML assigns each
  5237. // row of data a pseudo-random number between 0 and 100, and then selects
  5238. // the rows that have an assigned number between percentBegin and percentEnd.
  5239. // Pseudo-random numbers are assigned using both the input seed string value
  5240. // and the byte offset as a seed, so changing the data results in a different
  5241. // split. Any existing ordering is preserved. The random splitting strategy
  5242. // ensures that variables in the training and evaluation data are distributed
  5243. // similarly. It is useful in the cases where the input data may have an
  5244. // implicit sort order, which would otherwise result in training and evaluation
  5245. // datasources containing non-similar data records.
  5246. //
  5247. // The following two DataRearrangement lines are examples of non-sequentially
  5248. // ordered training and evaluation datasources:
  5249. //
  5250. // Datasource for evaluation: {"splitting":{"percentBegin":70, "percentEnd":100,
  5251. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv"}}
  5252. //
  5253. // Datasource for training: {"splitting":{"percentBegin":70, "percentEnd":100,
  5254. // "strategy":"random", "randomSeed"="s3://my_s3_path/bucket/file.csv", "complement":"true"}}
  5255. DataRearrangement *string `type:"string"`
  5256. // A JSON string that represents the schema for an Amazon S3 DataSource. The
  5257. // DataSchema defines the structure of the observation data in the data file(s)
  5258. // referenced in the DataSource.
  5259. //
  5260. // You must provide either the DataSchema or the DataSchemaLocationS3.
  5261. //
  5262. // Define your DataSchema as a series of key-value pairs. attributes and excludedVariableNames
  5263. // have an array of key-value pairs for their value. Use the following format
  5264. // to define your DataSchema.
  5265. //
  5266. // { "version": "1.0",
  5267. //
  5268. // "recordAnnotationFieldName": "F1",
  5269. //
  5270. // "recordWeightFieldName": "F2",
  5271. //
  5272. // "targetFieldName": "F3",
  5273. //
  5274. // "dataFormat": "CSV",
  5275. //
  5276. // "dataFileContainsHeader": true,
  5277. //
  5278. // "attributes": [
  5279. //
  5280. // { "fieldName": "F1", "fieldType": "TEXT" }, { "fieldName": "F2", "fieldType":
  5281. // "NUMERIC" }, { "fieldName": "F3", "fieldType": "CATEGORICAL" }, { "fieldName":
  5282. // "F4", "fieldType": "NUMERIC" }, { "fieldName": "F5", "fieldType": "CATEGORICAL"
  5283. // }, { "fieldName": "F6", "fieldType": "TEXT" }, { "fieldName": "F7", "fieldType":
  5284. // "WEIGHTED_INT_SEQUENCE" }, { "fieldName": "F8", "fieldType": "WEIGHTED_STRING_SEQUENCE"
  5285. // } ],
  5286. //
  5287. // "excludedVariableNames": [ "F6" ] }
  5288. DataSchema *string `type:"string"`
  5289. // Describes the schema location in Amazon S3. You must provide either the DataSchema
  5290. // or the DataSchemaLocationS3.
  5291. DataSchemaLocationS3 *string `type:"string"`
  5292. }
  5293. // String returns the string representation
  5294. func (s S3DataSpec) String() string {
  5295. return awsutil.Prettify(s)
  5296. }
  5297. // GoString returns the string representation
  5298. func (s S3DataSpec) GoString() string {
  5299. return s.String()
  5300. }
  5301. // Validate inspects the fields of the type to determine if they are valid.
  5302. func (s *S3DataSpec) Validate() error {
  5303. invalidParams := request.ErrInvalidParams{Context: "S3DataSpec"}
  5304. if s.DataLocationS3 == nil {
  5305. invalidParams.Add(request.NewErrParamRequired("DataLocationS3"))
  5306. }
  5307. if invalidParams.Len() > 0 {
  5308. return invalidParams
  5309. }
  5310. return nil
  5311. }
  5312. // A custom key-value pair associated with an ML object, such as an ML model.
  5313. type Tag struct {
  5314. _ struct{} `type:"structure"`
  5315. // A unique identifier for the tag. Valid characters include Unicode letters,
  5316. // digits, white space, _, ., /, =, +, -, %, and @.
  5317. Key *string `min:"1" type:"string"`
  5318. // An optional string, typically used to describe or define the tag. Valid characters
  5319. // include Unicode letters, digits, white space, _, ., /, =, +, -, %, and @.
  5320. Value *string `type:"string"`
  5321. }
  5322. // String returns the string representation
  5323. func (s Tag) String() string {
  5324. return awsutil.Prettify(s)
  5325. }
  5326. // GoString returns the string representation
  5327. func (s Tag) GoString() string {
  5328. return s.String()
  5329. }
  5330. // Validate inspects the fields of the type to determine if they are valid.
  5331. func (s *Tag) Validate() error {
  5332. invalidParams := request.ErrInvalidParams{Context: "Tag"}
  5333. if s.Key != nil && len(*s.Key) < 1 {
  5334. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  5335. }
  5336. if invalidParams.Len() > 0 {
  5337. return invalidParams
  5338. }
  5339. return nil
  5340. }
  5341. type UpdateBatchPredictionInput struct {
  5342. _ struct{} `type:"structure"`
  5343. // The ID assigned to the BatchPrediction during creation.
  5344. //
  5345. // BatchPredictionId is a required field
  5346. BatchPredictionId *string `min:"1" type:"string" required:"true"`
  5347. // A new user-supplied name or description of the BatchPrediction.
  5348. //
  5349. // BatchPredictionName is a required field
  5350. BatchPredictionName *string `type:"string" required:"true"`
  5351. }
  5352. // String returns the string representation
  5353. func (s UpdateBatchPredictionInput) String() string {
  5354. return awsutil.Prettify(s)
  5355. }
  5356. // GoString returns the string representation
  5357. func (s UpdateBatchPredictionInput) GoString() string {
  5358. return s.String()
  5359. }
  5360. // Validate inspects the fields of the type to determine if they are valid.
  5361. func (s *UpdateBatchPredictionInput) Validate() error {
  5362. invalidParams := request.ErrInvalidParams{Context: "UpdateBatchPredictionInput"}
  5363. if s.BatchPredictionId == nil {
  5364. invalidParams.Add(request.NewErrParamRequired("BatchPredictionId"))
  5365. }
  5366. if s.BatchPredictionId != nil && len(*s.BatchPredictionId) < 1 {
  5367. invalidParams.Add(request.NewErrParamMinLen("BatchPredictionId", 1))
  5368. }
  5369. if s.BatchPredictionName == nil {
  5370. invalidParams.Add(request.NewErrParamRequired("BatchPredictionName"))
  5371. }
  5372. if invalidParams.Len() > 0 {
  5373. return invalidParams
  5374. }
  5375. return nil
  5376. }
  5377. // Represents the output of an UpdateBatchPrediction operation.
  5378. //
  5379. // You can see the updated content by using the GetBatchPrediction operation.
  5380. type UpdateBatchPredictionOutput struct {
  5381. _ struct{} `type:"structure"`
  5382. // The ID assigned to the BatchPrediction during creation. This value should
  5383. // be identical to the value of the BatchPredictionId in the request.
  5384. BatchPredictionId *string `min:"1" type:"string"`
  5385. }
  5386. // String returns the string representation
  5387. func (s UpdateBatchPredictionOutput) String() string {
  5388. return awsutil.Prettify(s)
  5389. }
  5390. // GoString returns the string representation
  5391. func (s UpdateBatchPredictionOutput) GoString() string {
  5392. return s.String()
  5393. }
  5394. type UpdateDataSourceInput struct {
  5395. _ struct{} `type:"structure"`
  5396. // The ID assigned to the DataSource during creation.
  5397. //
  5398. // DataSourceId is a required field
  5399. DataSourceId *string `min:"1" type:"string" required:"true"`
  5400. // A new user-supplied name or description of the DataSource that will replace
  5401. // the current description.
  5402. //
  5403. // DataSourceName is a required field
  5404. DataSourceName *string `type:"string" required:"true"`
  5405. }
  5406. // String returns the string representation
  5407. func (s UpdateDataSourceInput) String() string {
  5408. return awsutil.Prettify(s)
  5409. }
  5410. // GoString returns the string representation
  5411. func (s UpdateDataSourceInput) GoString() string {
  5412. return s.String()
  5413. }
  5414. // Validate inspects the fields of the type to determine if they are valid.
  5415. func (s *UpdateDataSourceInput) Validate() error {
  5416. invalidParams := request.ErrInvalidParams{Context: "UpdateDataSourceInput"}
  5417. if s.DataSourceId == nil {
  5418. invalidParams.Add(request.NewErrParamRequired("DataSourceId"))
  5419. }
  5420. if s.DataSourceId != nil && len(*s.DataSourceId) < 1 {
  5421. invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1))
  5422. }
  5423. if s.DataSourceName == nil {
  5424. invalidParams.Add(request.NewErrParamRequired("DataSourceName"))
  5425. }
  5426. if invalidParams.Len() > 0 {
  5427. return invalidParams
  5428. }
  5429. return nil
  5430. }
  5431. // Represents the output of an UpdateDataSource operation.
  5432. //
  5433. // You can see the updated content by using the GetBatchPrediction operation.
  5434. type UpdateDataSourceOutput struct {
  5435. _ struct{} `type:"structure"`
  5436. // The ID assigned to the DataSource during creation. This value should be identical
  5437. // to the value of the DataSourceID in the request.
  5438. DataSourceId *string `min:"1" type:"string"`
  5439. }
  5440. // String returns the string representation
  5441. func (s UpdateDataSourceOutput) String() string {
  5442. return awsutil.Prettify(s)
  5443. }
  5444. // GoString returns the string representation
  5445. func (s UpdateDataSourceOutput) GoString() string {
  5446. return s.String()
  5447. }
  5448. type UpdateEvaluationInput struct {
  5449. _ struct{} `type:"structure"`
  5450. // The ID assigned to the Evaluation during creation.
  5451. //
  5452. // EvaluationId is a required field
  5453. EvaluationId *string `min:"1" type:"string" required:"true"`
  5454. // A new user-supplied name or description of the Evaluation that will replace
  5455. // the current content.
  5456. //
  5457. // EvaluationName is a required field
  5458. EvaluationName *string `type:"string" required:"true"`
  5459. }
  5460. // String returns the string representation
  5461. func (s UpdateEvaluationInput) String() string {
  5462. return awsutil.Prettify(s)
  5463. }
  5464. // GoString returns the string representation
  5465. func (s UpdateEvaluationInput) GoString() string {
  5466. return s.String()
  5467. }
  5468. // Validate inspects the fields of the type to determine if they are valid.
  5469. func (s *UpdateEvaluationInput) Validate() error {
  5470. invalidParams := request.ErrInvalidParams{Context: "UpdateEvaluationInput"}
  5471. if s.EvaluationId == nil {
  5472. invalidParams.Add(request.NewErrParamRequired("EvaluationId"))
  5473. }
  5474. if s.EvaluationId != nil && len(*s.EvaluationId) < 1 {
  5475. invalidParams.Add(request.NewErrParamMinLen("EvaluationId", 1))
  5476. }
  5477. if s.EvaluationName == nil {
  5478. invalidParams.Add(request.NewErrParamRequired("EvaluationName"))
  5479. }
  5480. if invalidParams.Len() > 0 {
  5481. return invalidParams
  5482. }
  5483. return nil
  5484. }
  5485. // Represents the output of an UpdateEvaluation operation.
  5486. //
  5487. // You can see the updated content by using the GetEvaluation operation.
  5488. type UpdateEvaluationOutput struct {
  5489. _ struct{} `type:"structure"`
  5490. // The ID assigned to the Evaluation during creation. This value should be identical
  5491. // to the value of the Evaluation in the request.
  5492. EvaluationId *string `min:"1" type:"string"`
  5493. }
  5494. // String returns the string representation
  5495. func (s UpdateEvaluationOutput) String() string {
  5496. return awsutil.Prettify(s)
  5497. }
  5498. // GoString returns the string representation
  5499. func (s UpdateEvaluationOutput) GoString() string {
  5500. return s.String()
  5501. }
  5502. type UpdateMLModelInput struct {
  5503. _ struct{} `type:"structure"`
  5504. // The ID assigned to the MLModel during creation.
  5505. //
  5506. // MLModelId is a required field
  5507. MLModelId *string `min:"1" type:"string" required:"true"`
  5508. // A user-supplied name or description of the MLModel.
  5509. MLModelName *string `type:"string"`
  5510. // The ScoreThreshold used in binary classification MLModel that marks the boundary
  5511. // between a positive prediction and a negative prediction.
  5512. //
  5513. // Output values greater than or equal to the ScoreThreshold receive a positive
  5514. // result from the MLModel, such as true. Output values less than the ScoreThreshold
  5515. // receive a negative response from the MLModel, such as false.
  5516. ScoreThreshold *float64 `type:"float"`
  5517. }
  5518. // String returns the string representation
  5519. func (s UpdateMLModelInput) String() string {
  5520. return awsutil.Prettify(s)
  5521. }
  5522. // GoString returns the string representation
  5523. func (s UpdateMLModelInput) GoString() string {
  5524. return s.String()
  5525. }
  5526. // Validate inspects the fields of the type to determine if they are valid.
  5527. func (s *UpdateMLModelInput) Validate() error {
  5528. invalidParams := request.ErrInvalidParams{Context: "UpdateMLModelInput"}
  5529. if s.MLModelId == nil {
  5530. invalidParams.Add(request.NewErrParamRequired("MLModelId"))
  5531. }
  5532. if s.MLModelId != nil && len(*s.MLModelId) < 1 {
  5533. invalidParams.Add(request.NewErrParamMinLen("MLModelId", 1))
  5534. }
  5535. if invalidParams.Len() > 0 {
  5536. return invalidParams
  5537. }
  5538. return nil
  5539. }
  5540. // Represents the output of an UpdateMLModel operation.
  5541. //
  5542. // You can see the updated content by using the GetMLModel operation.
  5543. type UpdateMLModelOutput struct {
  5544. _ struct{} `type:"structure"`
  5545. // The ID assigned to the MLModel during creation. This value should be identical
  5546. // to the value of the MLModelID in the request.
  5547. MLModelId *string `min:"1" type:"string"`
  5548. }
  5549. // String returns the string representation
  5550. func (s UpdateMLModelOutput) String() string {
  5551. return awsutil.Prettify(s)
  5552. }
  5553. // GoString returns the string representation
  5554. func (s UpdateMLModelOutput) GoString() string {
  5555. return s.String()
  5556. }
  5557. // The function used to train an MLModel. Training choices supported by Amazon
  5558. // ML include the following:
  5559. //
  5560. // * SGD - Stochastic Gradient Descent.
  5561. // * RandomForest - Random forest of decision trees.
  5562. const (
  5563. // AlgorithmSgd is a Algorithm enum value
  5564. AlgorithmSgd = "sgd"
  5565. )
  5566. // A list of the variables to use in searching or filtering BatchPrediction.
  5567. //
  5568. // * CreatedAt - Sets the search criteria to BatchPrediction creation date.
  5569. //
  5570. // * Status - Sets the search criteria to BatchPrediction status.
  5571. // * Name - Sets the search criteria to the contents of BatchPredictionName.
  5572. //
  5573. // * IAMUser - Sets the search criteria to the user account that invoked
  5574. // the BatchPrediction creation.
  5575. // * MLModelId - Sets the search criteria to the MLModel used in the BatchPrediction.
  5576. //
  5577. // * DataSourceId - Sets the search criteria to the DataSource used in the
  5578. // BatchPrediction.
  5579. // * DataURI - Sets the search criteria to the data file(s) used in the BatchPrediction.
  5580. // The URL can identify either a file or an Amazon Simple Storage Service
  5581. // (Amazon S3) bucket or directory.
  5582. const (
  5583. // BatchPredictionFilterVariableCreatedAt is a BatchPredictionFilterVariable enum value
  5584. BatchPredictionFilterVariableCreatedAt = "CreatedAt"
  5585. // BatchPredictionFilterVariableLastUpdatedAt is a BatchPredictionFilterVariable enum value
  5586. BatchPredictionFilterVariableLastUpdatedAt = "LastUpdatedAt"
  5587. // BatchPredictionFilterVariableStatus is a BatchPredictionFilterVariable enum value
  5588. BatchPredictionFilterVariableStatus = "Status"
  5589. // BatchPredictionFilterVariableName is a BatchPredictionFilterVariable enum value
  5590. BatchPredictionFilterVariableName = "Name"
  5591. // BatchPredictionFilterVariableIamuser is a BatchPredictionFilterVariable enum value
  5592. BatchPredictionFilterVariableIamuser = "IAMUser"
  5593. // BatchPredictionFilterVariableMlmodelId is a BatchPredictionFilterVariable enum value
  5594. BatchPredictionFilterVariableMlmodelId = "MLModelId"
  5595. // BatchPredictionFilterVariableDataSourceId is a BatchPredictionFilterVariable enum value
  5596. BatchPredictionFilterVariableDataSourceId = "DataSourceId"
  5597. // BatchPredictionFilterVariableDataUri is a BatchPredictionFilterVariable enum value
  5598. BatchPredictionFilterVariableDataUri = "DataURI"
  5599. )
  5600. // A list of the variables to use in searching or filtering DataSource.
  5601. //
  5602. // * CreatedAt - Sets the search criteria to DataSource creation date.
  5603. // * Status - Sets the search criteria to DataSource status.
  5604. // * Name - Sets the search criteria to the contents of DataSourceName.
  5605. // * DataUri - Sets the search criteria to the URI of data files used to
  5606. // create the DataSource. The URI can identify either a file or an Amazon
  5607. // Simple Storage Service (Amazon S3) bucket or directory.
  5608. // * IAMUser - Sets the search criteria to the user account that invoked
  5609. // the DataSource creation.
  5610. // NoteThe variable names should match the variable names in the DataSource.
  5611. const (
  5612. // DataSourceFilterVariableCreatedAt is a DataSourceFilterVariable enum value
  5613. DataSourceFilterVariableCreatedAt = "CreatedAt"
  5614. // DataSourceFilterVariableLastUpdatedAt is a DataSourceFilterVariable enum value
  5615. DataSourceFilterVariableLastUpdatedAt = "LastUpdatedAt"
  5616. // DataSourceFilterVariableStatus is a DataSourceFilterVariable enum value
  5617. DataSourceFilterVariableStatus = "Status"
  5618. // DataSourceFilterVariableName is a DataSourceFilterVariable enum value
  5619. DataSourceFilterVariableName = "Name"
  5620. // DataSourceFilterVariableDataLocationS3 is a DataSourceFilterVariable enum value
  5621. DataSourceFilterVariableDataLocationS3 = "DataLocationS3"
  5622. // DataSourceFilterVariableIamuser is a DataSourceFilterVariable enum value
  5623. DataSourceFilterVariableIamuser = "IAMUser"
  5624. )
  5625. // Contains the key values of DetailsMap: PredictiveModelType- Indicates the type of the MLModel. Algorithm- Indicates the algorithm that was used for the MLModel
  5626. const (
  5627. // DetailsAttributesPredictiveModelType is a DetailsAttributes enum value
  5628. DetailsAttributesPredictiveModelType = "PredictiveModelType"
  5629. // DetailsAttributesAlgorithm is a DetailsAttributes enum value
  5630. DetailsAttributesAlgorithm = "Algorithm"
  5631. )
  5632. // Object status with the following possible values:
  5633. //
  5634. // * PENDING
  5635. // * INPROGRESS
  5636. // * FAILED
  5637. // * COMPLETED
  5638. // * DELETED
  5639. const (
  5640. // EntityStatusPending is a EntityStatus enum value
  5641. EntityStatusPending = "PENDING"
  5642. // EntityStatusInprogress is a EntityStatus enum value
  5643. EntityStatusInprogress = "INPROGRESS"
  5644. // EntityStatusFailed is a EntityStatus enum value
  5645. EntityStatusFailed = "FAILED"
  5646. // EntityStatusCompleted is a EntityStatus enum value
  5647. EntityStatusCompleted = "COMPLETED"
  5648. // EntityStatusDeleted is a EntityStatus enum value
  5649. EntityStatusDeleted = "DELETED"
  5650. )
  5651. // A list of the variables to use in searching or filtering Evaluation.
  5652. //
  5653. // * CreatedAt - Sets the search criteria to Evaluation creation date.
  5654. // * Status - Sets the search criteria to Evaluation status.
  5655. // * Name - Sets the search criteria to the contents of EvaluationName.
  5656. // * IAMUser - Sets the search criteria to the user account that invoked
  5657. // an evaluation.
  5658. // * MLModelId - Sets the search criteria to the Predictor that was evaluated.
  5659. //
  5660. // * DataSourceId - Sets the search criteria to the DataSource used in evaluation.
  5661. //
  5662. // * DataUri - Sets the search criteria to the data file(s) used in evaluation.
  5663. // The URL can identify either a file or an Amazon Simple Storage Service
  5664. // (Amazon S3) bucket or directory.
  5665. const (
  5666. // EvaluationFilterVariableCreatedAt is a EvaluationFilterVariable enum value
  5667. EvaluationFilterVariableCreatedAt = "CreatedAt"
  5668. // EvaluationFilterVariableLastUpdatedAt is a EvaluationFilterVariable enum value
  5669. EvaluationFilterVariableLastUpdatedAt = "LastUpdatedAt"
  5670. // EvaluationFilterVariableStatus is a EvaluationFilterVariable enum value
  5671. EvaluationFilterVariableStatus = "Status"
  5672. // EvaluationFilterVariableName is a EvaluationFilterVariable enum value
  5673. EvaluationFilterVariableName = "Name"
  5674. // EvaluationFilterVariableIamuser is a EvaluationFilterVariable enum value
  5675. EvaluationFilterVariableIamuser = "IAMUser"
  5676. // EvaluationFilterVariableMlmodelId is a EvaluationFilterVariable enum value
  5677. EvaluationFilterVariableMlmodelId = "MLModelId"
  5678. // EvaluationFilterVariableDataSourceId is a EvaluationFilterVariable enum value
  5679. EvaluationFilterVariableDataSourceId = "DataSourceId"
  5680. // EvaluationFilterVariableDataUri is a EvaluationFilterVariable enum value
  5681. EvaluationFilterVariableDataUri = "DataURI"
  5682. )
  5683. const (
  5684. // MLModelFilterVariableCreatedAt is a MLModelFilterVariable enum value
  5685. MLModelFilterVariableCreatedAt = "CreatedAt"
  5686. // MLModelFilterVariableLastUpdatedAt is a MLModelFilterVariable enum value
  5687. MLModelFilterVariableLastUpdatedAt = "LastUpdatedAt"
  5688. // MLModelFilterVariableStatus is a MLModelFilterVariable enum value
  5689. MLModelFilterVariableStatus = "Status"
  5690. // MLModelFilterVariableName is a MLModelFilterVariable enum value
  5691. MLModelFilterVariableName = "Name"
  5692. // MLModelFilterVariableIamuser is a MLModelFilterVariable enum value
  5693. MLModelFilterVariableIamuser = "IAMUser"
  5694. // MLModelFilterVariableTrainingDataSourceId is a MLModelFilterVariable enum value
  5695. MLModelFilterVariableTrainingDataSourceId = "TrainingDataSourceId"
  5696. // MLModelFilterVariableRealtimeEndpointStatus is a MLModelFilterVariable enum value
  5697. MLModelFilterVariableRealtimeEndpointStatus = "RealtimeEndpointStatus"
  5698. // MLModelFilterVariableMlmodelType is a MLModelFilterVariable enum value
  5699. MLModelFilterVariableMlmodelType = "MLModelType"
  5700. // MLModelFilterVariableAlgorithm is a MLModelFilterVariable enum value
  5701. MLModelFilterVariableAlgorithm = "Algorithm"
  5702. // MLModelFilterVariableTrainingDataUri is a MLModelFilterVariable enum value
  5703. MLModelFilterVariableTrainingDataUri = "TrainingDataURI"
  5704. )
  5705. const (
  5706. // MLModelTypeRegression is a MLModelType enum value
  5707. MLModelTypeRegression = "REGRESSION"
  5708. // MLModelTypeBinary is a MLModelType enum value
  5709. MLModelTypeBinary = "BINARY"
  5710. // MLModelTypeMulticlass is a MLModelType enum value
  5711. MLModelTypeMulticlass = "MULTICLASS"
  5712. )
  5713. const (
  5714. // RealtimeEndpointStatusNone is a RealtimeEndpointStatus enum value
  5715. RealtimeEndpointStatusNone = "NONE"
  5716. // RealtimeEndpointStatusReady is a RealtimeEndpointStatus enum value
  5717. RealtimeEndpointStatusReady = "READY"
  5718. // RealtimeEndpointStatusUpdating is a RealtimeEndpointStatus enum value
  5719. RealtimeEndpointStatusUpdating = "UPDATING"
  5720. // RealtimeEndpointStatusFailed is a RealtimeEndpointStatus enum value
  5721. RealtimeEndpointStatusFailed = "FAILED"
  5722. )
  5723. // The sort order specified in a listing condition. Possible values include
  5724. // the following:
  5725. //
  5726. // * asc - Present the information in ascending order (from A-Z).
  5727. // * dsc - Present the information in descending order (from Z-A).
  5728. const (
  5729. // SortOrderAsc is a SortOrder enum value
  5730. SortOrderAsc = "asc"
  5731. // SortOrderDsc is a SortOrder enum value
  5732. SortOrderDsc = "dsc"
  5733. )
  5734. const (
  5735. // TaggableResourceTypeBatchPrediction is a TaggableResourceType enum value
  5736. TaggableResourceTypeBatchPrediction = "BatchPrediction"
  5737. // TaggableResourceTypeDataSource is a TaggableResourceType enum value
  5738. TaggableResourceTypeDataSource = "DataSource"
  5739. // TaggableResourceTypeEvaluation is a TaggableResourceType enum value
  5740. TaggableResourceTypeEvaluation = "Evaluation"
  5741. // TaggableResourceTypeMlmodel is a TaggableResourceType enum value
  5742. TaggableResourceTypeMlmodel = "MLModel"
  5743. )