1. Short title This Act may be cited as the Farm Risk Abatement and Mitigation Election Act of 2017 or the FRAME Act of 2017 . 2. Farm risk management accounts (a) In general Part VII of subchapter B of chapter 1 of the Internal Revenue Code of 1986 is amended by redesignating section 224 as section 225 and by inserting after section 223 the following new section: 224. FRAME accounts (a) Deduction allowed In the case of a qualified farmer, there shall be allowed as a deduction for the taxable year an amount equal to the aggregate amount paid in cash during such taxable year by or on behalf of such individual to a FRAME account of such individual. (b) Limitation The amount allowable as a deduction under subsection (a) shall not exceed the least of the following: (1) The taxable income of the taxpayer for the taxable year which is attributable to farming and ranching. (2) $50,000. (3) $500,000 reduced by the aggregate contributions of the taxpayer to all FRAME accounts of the taxpayer for all taxable years. (c) Qualified farmer For purposes of this section, the term qualified farmer means, with respect to any taxable year, any individual who, during such year— (1) was actively engaged in the trade or business of farming or ranching, and (2) has in effect an agreement with the Secretary of Agriculture with respect to each FRAME account of which the individual is an account beneficiary. (d) FRAME account For purposes of this section— (1) In general The term FRAME account means a trust created or organized in the United States as a FRAME account exclusively for the purpose of making qualified distributions, but only if the written governing instrument creating the trust meets the following requirements: (A) No contribution will be accepted unless it is in cash. (B) The trustee is a bank (as defined in section 408(n)) or another person who demonstrates to the satisfaction of the Secretary that the manner in which such person will administer the trust will be consistent with the requirements of this section. (C) The