the latvian soviet socialist republic (latvian ssr; ; , "latviyskaya sovetskaya sotsialisticheskaya respublika"), also known as soviet latvia or latvia, was part of the soviet union, and existed from 1918 to 1920, and from 1940 to 1990.